/* ===================================
   About Section
   =================================== */

.about-section {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    background:
        linear-gradient(180deg, color-mix(in srgb, var(--bg) 94%, white), var(--bg));
    overflow: clip;
}

.about-shell {
    position: relative;
    padding: 1rem 0;
    isolation: isolate;
}

.about-backdrop {
    position: absolute;
    inset: -2rem -2rem auto;
    height: clamp(20rem, 42vw, 30rem);
    pointer-events: none;
    z-index: 0;
}

.about-backdrop::after {
    content: "";
    position: absolute;
    right: 6%;
    bottom: -4rem;
    width: clamp(11rem, 17vw, 15rem);
    height: clamp(11rem, 17vw, 15rem);
    border-radius: 999px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.16), transparent 72%);
    filter: blur(18px);
    opacity: 0.72;
    animation: about-backdrop-float 18s ease-in-out infinite;
    animation-delay: -9s;
}

.about-backdrop-orb,
.about-backdrop-grid {
    position: absolute;
    pointer-events: none;
}

.about-backdrop-orb {
    border-radius: 999px;
    filter: blur(18px);
    opacity: 0.8;
    animation: about-backdrop-float 16s ease-in-out infinite;
}

.about-backdrop-orb-one {
    top: 1rem;
    left: auto;
    right: 18%;
    width: clamp(11rem, 16vw, 15rem);
    height: clamp(11rem, 16vw, 15rem);
    background: radial-gradient(circle, rgba(99, 102, 241, 0.3), transparent 68%);
}

.about-backdrop-orb-two {
    display: block;
    left: 8%;
    top: auto;
    bottom: -1.5rem;
    width: clamp(10rem, 15vw, 14rem);
    height: clamp(10rem, 15vw, 14rem);
    background: radial-gradient(circle, rgba(99, 102, 241, 0.2), transparent 70%);
    animation-delay: -6s;
}

.about-backdrop-grid {
    inset: 2rem 0 auto;
    height: 16rem;
    background-image:
        linear-gradient(rgba(99, 102, 241, 0.16) 1px, transparent 1px),
        linear-gradient(90deg, rgba(99, 102, 241, 0.16) 1px, transparent 1px);
    background-size: 2.6rem 2.6rem;
    mask-image: radial-gradient(circle at center, rgba(0, 0, 0, 0.74), transparent 84%);
    opacity: 0.68;
}

.section-heading {
    position: relative;
    z-index: 1;
    max-width: 100%;
    margin-bottom: 1.15rem;
}

.section-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    margin-bottom: 0.85rem;
    padding: 0.45rem 0.8rem;
    border-radius: 999px;
    border: 1px solid color-mix(in srgb, var(--border) 76%, transparent);
    background: color-mix(in srgb, var(--surface) 72%, transparent);
    color: var(--text-secondary);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.section-kicker::before {
    content: "";
    width: 0.45rem;
    height: 0.45rem;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 14px rgba(99, 102, 241, 0.32);
}

.section-heading h2 {
    margin-bottom: 0.65rem;
    max-width: 100%;
    font-size: clamp(1.8rem, 3vw, 2.7rem);
    line-height: 1.03;
    letter-spacing: -0.04em;
}

.section-heading p {
    max-width: 41rem;
    margin-bottom: 0;
    font-size: 1rem;
    line-height: 1.76;
}

.about-layout {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(20rem, 24rem) minmax(0, 1fr);
    gap: clamp(3rem, 5vw, 5.25rem);
    align-items: center;
}

.about-visual-column {
    display: grid;
    justify-items: center;
    align-content: start;
    position: static;
}

.about-avatar-card {
    position: relative;
    min-height: 0;
    display: grid;
    justify-items: center;
    gap: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    isolation: isolate;
}

.about-avatar-card::before {
    content: "";
    position: absolute;
    inset: -13%;
    border-radius: 50%;
    background:
        radial-gradient(circle at center, rgba(99, 102, 241, 0.22), transparent 58%);
    filter: blur(42px);
    opacity: 0.74;
    z-index: 0;
    animation: about-avatar-aura 10s ease-in-out infinite;
    pointer-events: none;
}

.about-avatar-slot {
    width: min(100%, 22.75rem);
    aspect-ratio: 1 / 1;
    position: relative;
    display: grid;
    place-items: center;
    border-radius: 50%;
    overflow: hidden;
    background: transparent;
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.05),
        0 0 42px rgba(99, 102, 241, 0.28),
        0 0 104px rgba(255, 255, 255, 0.22),
        0 18px 40px rgba(15, 23, 42, 0.1);
    z-index: 1;
    transition:
        box-shadow 0.55s ease,
        transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
    animation: about-avatar-glow 7s ease-in-out infinite;
}

.about-avatar-slot img {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: inherit;
    display: block;
    transform: none;
    filter: saturate(1.02) contrast(1.02);
    transition:
        filter 0.55s ease;
}

.about-content {
    display: grid;
    gap: 1.1rem;
    padding-top: 0.2rem;
    padding-left: clamp(0.35rem, 1.4vw, 1rem);
    max-width: 100%;
    justify-items: start;
}

.about-titling {
    display: grid;
    gap: 0.2rem;
    margin-bottom: 0.15rem;
}

.about-identity-row {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    flex-wrap: wrap;
}

.about-name {
    color: var(--text);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    background: linear-gradient(135deg, var(--text), color-mix(in srgb, var(--text) 72%, var(--accent)));
    background-clip: text;
    -webkit-background-clip: text;
}

.about-status {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.38rem 0.72rem;
    border-radius: 999px;
    border: 1px solid color-mix(in srgb, var(--border) 76%, transparent);
    background: color-mix(in srgb, var(--surface) 72%, transparent);
    color: var(--text-secondary);
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    position: relative;
    overflow: hidden;
}

.about-status::before {
    content: "";
    width: 0.42rem;
    height: 0.42rem;
    border-radius: 50%;
    background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 88%, white), var(--accent));
    box-shadow: 0 0 14px color-mix(in srgb, var(--accent) 32%, transparent);
}

.about-status::after {
    content: "";
    position: absolute;
    inset: -35% auto -35% -40%;
    width: 34%;
    background: linear-gradient(
        115deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.08) 35%,
        rgba(255, 255, 255, 0.24) 50%,
        rgba(99, 102, 241, 0.12) 62%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: translateX(0) skewX(-22deg);
    filter: blur(4px);
    opacity: 0.78;
    animation: about-status-shimmer 6.8s cubic-bezier(0.22, 1, 0.36, 1) infinite;
    pointer-events: none;
}

.about-role {
    color: var(--text-muted);
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.about-facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem 1rem;
    max-width: 46rem;
}

.about-fact {
    display: grid;
    gap: 0.2rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid color-mix(in srgb, var(--border) 72%, transparent);
    position: relative;
    overflow: hidden;
    opacity: 0;
    transform: translateY(18px);
    filter: blur(8px);
}

.about-fact::after {
    content: "";
    position: absolute;
    inset: auto 0 -1px;
    height: 1px;
    background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--accent) 38%, transparent), transparent);
    opacity: 0.75;
    transform: scaleX(0.68);
    transform-origin: left center;
    transition: transform 0.35s ease, opacity 0.35s ease;
}

.about-fact-label {
    color: var(--text-muted);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.about-fact strong {
    color: var(--text);
    font-size: 0.96rem;
    font-weight: 600;
    line-height: 1.55;
}

.about-fact:hover::after {
    transform: scaleX(1);
    opacity: 1;
}

.about-shell.animate-in .about-fact {
    animation: about-fact-reveal 0.72s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.about-shell.animate-in .about-fact:nth-child(1) {
    animation-delay: 0.2s;
}

.about-shell.animate-in .about-fact:nth-child(2) {
    animation-delay: 0.28s;
}

.about-shell.animate-in .about-fact:nth-child(3) {
    animation-delay: 0.36s;
}

.about-shell.animate-in .about-fact:nth-child(4) {
    animation-delay: 0.44s;
}

.about-shell.animate-in .about-fact:nth-child(5) {
    animation-delay: 0.52s;
}

.about-shell.animate-in .about-fact:nth-child(6) {
    animation-delay: 0.6s;
}

.about-summary {
    max-width: 43rem;
    margin-bottom: 0;
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.86;
}

.skills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    max-width: 44rem;
}

.skills-rail {
    position: relative;
    left: 50%;
    width: 100vw;
    max-width: 100vw;
    margin-top: 1.25rem;
    margin-left: -50vw;
    padding-top: 1.35rem;
    overflow: hidden;
}

.skills-rail-viewport {
    position: relative;
    overflow: hidden;
    mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.skills-rail-track {
    display: flex;
    align-items: center;
    gap: 0;
    width: max-content;
    padding-top: 0.2rem;
    transform: translate3d(var(--skills-offset, 0px), 0, 0);
    will-change: transform;
}

.skills-rail-group {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
}

.skill-tag {
    display: inline-flex;
    align-items: center;
    flex: 0 0 auto;
    padding: 0.3rem 0 0.3rem 1.5rem;
    border-radius: 999px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.92rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    position: relative;
}

.skill-tag::before {
    content: "";
    width: 0.38rem;
    height: 0.38rem;
    margin-right: 0.55rem;
    border-radius: 50%;
    background: color-mix(in srgb, var(--accent) 84%, white);
    box-shadow: 0 0 14px rgba(99, 102, 241, 0.22);
}

[data-theme="dark"] .about-section {
    background:
        linear-gradient(180deg, color-mix(in srgb, var(--bg) 94%, var(--bg-secondary)), var(--bg));
}

[data-theme="dark"] .about-backdrop-orb-one {
    left: auto;
    right: 18%;
    width: clamp(11rem, 16vw, 15rem);
    height: clamp(11rem, 16vw, 15rem);
    background: radial-gradient(circle, rgba(165, 180, 252, 0.2), transparent 68%);
}

[data-theme="dark"] .about-backdrop-orb-two {
    display: block;
    left: 8%;
    top: auto;
    bottom: -1.5rem;
    width: clamp(10rem, 15vw, 14rem);
    height: clamp(10rem, 15vw, 14rem);
    background: radial-gradient(circle, rgba(196, 181, 253, 0.14), transparent 70%);
}

[data-theme="dark"] .about-backdrop::after {
    background: radial-gradient(circle, rgba(56, 189, 248, 0.08), transparent 72%);
    opacity: 0.5;
}

[data-theme="dark"] .about-backdrop-grid {
    background-image:
        linear-gradient(rgba(129, 140, 248, 0.16) 1px, transparent 1px),
        linear-gradient(90deg, rgba(129, 140, 248, 0.16) 1px, transparent 1px);
    opacity: 0.52;
}

[data-theme="dark"] .about-status {
    border-color: rgba(255, 255, 255, 0.1);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.02)),
        rgba(28, 25, 23, 0.28);
}

[data-theme="dark"] .about-status::after {
    background: linear-gradient(
        115deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.04) 35%,
        rgba(129, 140, 248, 0.16) 52%,
        rgba(255, 255, 255, 0.02) 64%,
        rgba(255, 255, 255, 0) 100%
    );
    opacity: 0.72;
}

[data-theme="dark"] .about-avatar-card::before {
    background:
        radial-gradient(circle at center, rgba(129, 140, 248, 0.16), transparent 58%);
    opacity: 0.62;
}

[data-theme="dark"] .about-avatar-slot img {
    filter: saturate(1.05) contrast(1.05);
}

[data-theme="dark"] .about-avatar-slot {
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.04),
        0 0 34px rgba(129, 140, 248, 0.24),
        0 0 82px rgba(56, 189, 248, 0.14),
        0 20px 44px rgba(0, 0, 0, 0.22);
}

.about-content > *:not(.about-facts) {
    opacity: 0;
    transform: translateY(22px);
    filter: blur(10px);
    transition:
        opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
        transform 0.7s cubic-bezier(0.22, 1, 0.36, 1),
        filter 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.about-shell.animate-in .about-content > *:not(.about-facts) {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
}

.about-shell.animate-in .about-titling {
    animation: about-text-shimmer 1.05s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.about-shell.animate-in .section-heading h2,
.about-shell.animate-in .section-heading p {
    animation: about-text-soften 1.05s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.about-shell.animate-in .about-content > :nth-child(1) {
    transition-delay: 0.06s;
}

.about-shell.animate-in .about-content > :nth-child(2) {
    transition-delay: 0.14s;
}

.about-shell.animate-in .about-content > :nth-child(3) {
    transition-delay: 0.24s;
}

.about-shell.animate-in .about-content > :nth-child(4) {
    transition-delay: 0.32s;
}

.about-avatar-card:hover .about-avatar-slot img,
.about-avatar-card:focus-within .about-avatar-slot img {
    transform: none;
    filter: saturate(1.05) contrast(1.04);
}

.about-avatar-card:hover .about-avatar-slot,
.about-avatar-card:focus-within .about-avatar-slot {
    transform: none;
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.07),
        0 0 56px rgba(99, 102, 241, 0.32),
        0 0 122px rgba(255, 255, 255, 0.24),
        0 22px 48px rgba(15, 23, 42, 0.12);
}

[data-theme="dark"] .about-avatar-card:hover .about-avatar-slot,
[data-theme="dark"] .about-avatar-card:focus-within .about-avatar-slot {
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.05),
        0 0 42px rgba(129, 140, 248, 0.28),
        0 0 104px rgba(56, 189, 248, 0.18),
        0 22px 48px rgba(0, 0, 0, 0.26);
}

.about-shell.animate-in .skills-rail-line::after {
    animation-delay: 0.75s;
}

@keyframes about-avatar-glow {
    0%,
    100% {
        box-shadow:
            0 0 0 1px rgba(255, 255, 255, 0.05),
            0 0 36px rgba(99, 102, 241, 0.24),
            0 0 92px rgba(255, 255, 255, 0.18),
            0 18px 40px rgba(15, 23, 42, 0.1);
    }

    50% {
        box-shadow:
            0 0 0 1px rgba(255, 255, 255, 0.07),
            0 0 52px rgba(99, 102, 241, 0.32),
            0 0 124px rgba(255, 255, 255, 0.24),
            0 18px 40px rgba(15, 23, 42, 0.1);
    }
}

@keyframes about-avatar-aura {
    0%,
    100% {
        opacity: 0.56;
        transform: scale(0.96);
    }

    50% {
        opacity: 0.84;
        transform: scale(1.04);
    }
}

[data-theme="dark"] .about-avatar-slot {
    animation-name: about-avatar-glow-dark;
}

@keyframes about-avatar-glow-dark {
    0%,
    100% {
        box-shadow:
            0 0 0 1px rgba(255, 255, 255, 0.04),
            0 0 30px rgba(129, 140, 248, 0.22),
            0 0 78px rgba(56, 189, 248, 0.12),
            0 20px 44px rgba(0, 0, 0, 0.22);
    }

    50% {
        box-shadow:
            0 0 0 1px rgba(255, 255, 255, 0.05),
            0 0 42px rgba(129, 140, 248, 0.28),
            0 0 104px rgba(56, 189, 248, 0.16),
            0 20px 44px rgba(0, 0, 0, 0.22);
    }
}

@keyframes about-text-shimmer {
    0% {
        opacity: 0;
        filter: blur(12px);
        transform: translateY(18px);
    }

    100% {
        opacity: 1;
        filter: blur(0);
        transform: translateY(0);
    }
}

@keyframes about-text-soften {
    0% {
        opacity: 0;
        filter: blur(16px);
        transform: translateY(22px);
    }

    100% {
        opacity: 1;
        filter: blur(0);
        transform: translateY(0);
    }
}

@keyframes about-fact-reveal {
    0% {
        opacity: 0;
        transform: translateY(18px);
        filter: blur(8px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}

@keyframes about-status-shimmer {
    0% {
        transform: translateX(0) skewX(-22deg);
        opacity: 0;
    }

    16% {
        opacity: 0.78;
    }

    100% {
        transform: translateX(420%) skewX(-22deg);
        opacity: 0;
    }
}

@keyframes about-backdrop-float {
    0%,
    100% {
        transform: translate3d(0, 0, 0);
    }

    50% {
        transform: translate3d(0, -14px, 0);
    }
}

@media (max-width: 980px) {
    .about-layout {
        grid-template-columns: 1fr;
        gap: 2.25rem;
    }

    .about-visual-column {
        position: static;
        order: -1;
    }

    .about-avatar-slot {
        width: min(100%, 19rem);
    }

    .about-avatar-ornament-one {
        right: 2%;
        bottom: 38%;
    }

    .about-avatar-ornament-two {
        right: -2%;
        bottom: 10%;
    }

    .about-avatar-ornament-three {
        right: 4%;
        bottom: -10%;
    }

    .about-content {
        padding-left: 0;
    }

    .about-identity-row {
        gap: 0.65rem;
    }

    .about-content,
    .about-facts,
    .skills {
        max-width: 100%;
    }

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

    .skills-rail {
        left: 50%;
        width: 100vw;
        margin-left: -50vw;
    }

    .skills-rail-track {
        gap: 0;
    }

    .skill-tag {
        padding-left: 1.15rem;
    }

}

@media (max-width: 768px) {
    .section-shell {
        padding: 1.15rem;
        border-radius: 1.5rem;
    }

    .section-heading {
        margin-bottom: 1.4rem;
    }

    .section-heading h2 {
        max-width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .about-avatar-slot,
    .about-avatar-card::before,
    .about-backdrop::after,
    .about-backdrop-orb,
    .skills-rail-track,
    .about-status::after,
    .about-shell.animate-in .about-titling,
    .about-shell.animate-in .section-heading h2,
    .about-shell.animate-in .section-heading p {
        animation: none;
    }

    .about-content > * {
        opacity: 1;
        transform: none;
        filter: none;
        transition: none;
    }

    .about-fact {
        opacity: 1;
        transform: none;
        filter: none;
        transition: none;
    }
}
