/* =========================================================
   ELENE HOVSEPYAN PORTFOLIO — COMPLETE STYLESHEET
   Replace the entire existing style.css with this file.
   ========================================================= */


/* =========================================================
   1. DESIGN TOKENS
   ========================================================= */

:root {
    --background: #f7f5fb;
    --background-secondary: #ffffff;
    --surface: #ffffff;
    --surface-soft: #eee9fa;
    --surface-strong: #e1d8f6;

    --text: #17131f;
    --text-soft: #5f596b;
    --text-faint: #837b91;

    --primary: #7d5acd;
    --primary-hover: #8b69d8;
    --primary-light: #a98be7;

    --border: rgba(56, 41, 83, 0.14);
    --shadow-soft: 0 14px 36px rgba(49, 28, 82, 0.07);
    --shadow-medium: 0 24px 58px rgba(49, 28, 82, 0.13);
    --shadow-strong: 0 30px 80px rgba(35, 20, 58, 0.2);

    --container-width: 1180px;
    --header-height: 64px;
}

body.dark-theme {
    --background: #111016;
    --background-secondary: #17151e;
    --surface: #1c1924;
    --surface-soft: #272131;
    --surface-strong: #33283f;

    --text: #f4f0fa;
    --text-soft: #bcb5c7;
    --text-faint: #948c9e;

    --border: rgba(228, 216, 245, 0.13);
    --shadow-soft: 0 14px 36px rgba(0, 0, 0, 0.22);
    --shadow-medium: 0 24px 58px rgba(0, 0, 0, 0.3);
    --shadow-strong: 0 30px 80px rgba(0, 0, 0, 0.42);
}


/* =========================================================
   2. RESET AND GLOBAL ELEMENTS
   ========================================================= */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
    background: var(--background);
    color: var(--text);
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.65;
    transition: background 0.3s ease, color 0.3s ease;
}

body.menu-open {
    overflow: hidden;
}

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

a {
    color: inherit;
    text-decoration: none;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

button {
    color: inherit;
    font: inherit;
}

.container {
    width: min(92%, var(--container-width));
    margin-inline: auto;
}

.section {
    padding: 110px 0;
}


/* =========================================================
   3. SHARED SECTION TYPOGRAPHY
   ========================================================= */

.section-heading {
    display: grid;
    grid-template-columns: 20px minmax(0, 1fr);
    gap: 30px;
    align-items: start;
    margin-bottom: 64px;
}

.section-number {
    color: var(--primary);
    font-size: 0.9rem;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.section-label {
    color: var(--primary);
    font-size: 0.78rem;
    font-weight: 850;
    letter-spacing: 0.18em;
    margin-bottom: 14px;
    text-transform: uppercase;
}

.section-heading h2 {
    max-width: 1050px;
    font-size: clamp(2.25rem, 4.5vw, 4rem);
    font-weight: 720;
    letter-spacing: -0.055em;
    line-height: 1.04;
}


/* =========================================================
   4. CURSOR GLOW
   ========================================================= */

.cursor-glow {
    position: fixed;
    z-index: 0;
    width: 380px;
    height: 380px;
    border-radius: 50%;
    pointer-events: none;
    background: radial-gradient(
        circle,
        rgba(132, 86, 220, 0.12),
        transparent 68%
    );
    opacity: 0;
    transform: translate(-50%, -50%);
    transition: opacity 0.25s ease;
}


/* =========================================================
   5. FLOATING HEADER
   ========================================================= */

.site-header {
    position: fixed;
    top: 18px;
    left: 0;
    right: 0;
    z-index: 1000;
    width: 100%;
    pointer-events: none;
}

.header-shell {
    pointer-events: auto;
    background: color-mix(in srgb, var(--surface) 94%, transparent);
    border: 1px solid var(--border);
    border-radius: 28px;
    box-shadow: 0 16px 40px rgba(46, 28, 76, 0.11);
    backdrop-filter: blur(18px);
    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        background 0.25s ease;
}

.site-header.scrolled .header-shell {
    box-shadow: 0 18px 48px rgba(46, 28, 76, 0.16);
    transform: translateY(-2px);
}

.navbar {
    position: relative;
    min-height: var(--header-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
}

.logo {
    z-index: 2;
    display: inline-block;
    padding-left: 8px;
    font-size: 1.45rem;
    font-weight: 900;
    letter-spacing: -0.05em;
}

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

.desktop-navigation {
    display: flex;
    gap: 34px;
}

.desktop-navigation a,
.mobile-navigation a {
    color: var(--text-soft);
    font-size: 0.92rem;
    font-weight: 650;
    transition: color 0.2s ease;
}

.desktop-navigation a:hover,
.desktop-navigation a.active,
.mobile-navigation a:hover,
.mobile-navigation a.active {
    color: var(--primary);
}

.navigation-actions {
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 10px;
}

.theme-button,
.menu-button {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    background: var(--surface-soft);
    border: 1px solid var(--border);
    border-radius: 16px;
    cursor: pointer;
}

.menu-button {
    display: none;
    gap: 4px;
    align-content: center;
}

.menu-button span {
    width: 17px;
    height: 1.5px;
    display: block;
    background: var(--text);
    transition: transform 0.25s ease, opacity 0.25s ease;
}

.menu-button.active span:nth-child(1) {
    transform: translateY(5.5px) rotate(45deg);
}

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

.menu-button.active span:nth-child(3) {
    transform: translateY(-5.5px) rotate(-45deg);
}

.mobile-navigation {
    display: none;
}


/* =========================================================
   6. HERO
   ========================================================= */

.hero-section {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    display: flex;
    align-items: center;
    padding: calc(var(--header-height) + 56px) 0 72px;
    background:
        radial-gradient(
            circle at 72% 28%,
            rgba(146, 104, 222, 0.13),
            transparent 29%
        ),
        radial-gradient(
            circle at 16% 84%,
            rgba(196, 176, 235, 0.14),
            transparent 30%
        ),
        var(--background);
}

.hero-grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 68px;
    align-items: center;
}

.hero-cloud {
    position: absolute;
    pointer-events: none;
    border-radius: 48% 52% 55% 45% / 58% 42% 58% 42%;
    filter: blur(1px);
    opacity: 0.9;
}

.hero-cloud-one {
    top: 13%;
    right: 2%;
    width: 430px;
    height: 260px;
    background: rgba(185, 157, 231, 0.16);
    transform: rotate(-8deg);
}

.hero-cloud-two {
    top: 27%;
    right: 18%;
    width: 300px;
    height: 190px;
    background: rgba(232, 221, 247, 0.7);
    transform: rotate(11deg);
}

.hero-cloud-three {
    bottom: 5%;
    left: -6%;
    width: 360px;
    height: 210px;
    background: rgba(205, 187, 238, 0.14);
    transform: rotate(8deg);
}

.availability-badge {
    width: fit-content;
    display: flex;
    align-items: center;
    gap: 9px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 999px;
    box-shadow: 0 10px 35px rgba(58, 35, 92, 0.06);
    color: var(--text-soft);
    font-size: 0.82rem;
    font-weight: 650;
    padding: 9px 14px;
    margin-bottom: 28px;
}

.availability-dot {
    width: 8px;
    height: 8px;
    background: #39a66d;
    border-radius: 50%;
    box-shadow: 0 0 0 5px rgba(57, 166, 109, 0.13);
}

.hero-introduction {
    color: var(--text-soft);
    font-size: 1.05rem;
    margin-bottom: 4px;
}

.hero-content h1 {
    color: var(--primary);
    font-size: clamp(4rem, 7vw, 7rem);
    font-weight: 760;
    letter-spacing: 0.005em;
    line-height: 0.95;
}

.hero-content h1 span {
    display: inline;
}

.full-name-accent {
    color: var(--primary);
}
.full-name-accent1 {
    color: var(--text);
}

.hero-content h2 {
    max-width: 740px;
    color: var(--text);
    font-size: clamp(1.45rem, 3vw, 2.15rem);
    font-weight: 500;
    line-height: 1.28;
    margin: 25px 0 18px;
}

.hero-description {
    max-width: 680px;
    color: var(--text-soft);
    font-size: 1.07rem;
    line-height: 1.65;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin: 32px 0 18px;
}

.button {
    min-height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: 0.92rem;
    font-weight: 750;
    padding: 0 24px;
    transition:
        transform 0.2s ease,
        background 0.2s ease,
        border-color 0.2s ease,
        color 0.2s ease,
        box-shadow 0.2s ease;
}

.button:hover {
    transform: translateY(-3px);
}

.primary-button {
    background: var(--primary);
    color: #ffffff;
}

.primary-button:hover {
    background: var(--primary-hover);
    color: #ffffff;
    box-shadow: 0 15px 35px rgba(125, 90, 205, 0.28);
}

body.dark-theme .primary-button {
    color: #111111;
}

body.dark-theme .primary-button:hover {
    color: #111111;
}

.secondary-button {
    background: var(--surface);
    border-color: var(--border);
}

.secondary-button:hover {
    border-color: var(--primary);
}

.hero-socials {
    display: flex;
    gap: 24px;
    padding-left: 10px;
}

.hero-socials a {
    color: var(--text-soft);
    font-size: 0.9rem;
    font-weight: 650;
}

.hero-socials a:hover {
    color: var(--primary);
}

.hero-visual {
    position: relative;
    width: 100%;
    max-width: 500px;
    justify-self: end;
    padding: 28px;
}

.portrait-frame {
    position: relative;
    z-index: 2;
    overflow: hidden;
    aspect-ratio: 4 / 5;
    background: var(--surface-soft);
    border: 7px solid var(--surface);
    border-radius: 46% 46% 43% 43% / 40% 40% 52% 52%;
    box-shadow: 0 24px 65px rgba(50, 31, 82, 0.16);
}

.portrait-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
}

.portrait-cloud {
    position: absolute;
    pointer-events: none;
}

.portrait-cloud-back {
    inset: 6% -3% 1% 8%;
    background: linear-gradient(
        145deg,
        rgba(173, 138, 225, 0.28),
        rgba(224, 212, 244, 0.55)
    );
    border-radius: 47% 53% 46% 54% / 48% 43% 57% 52%;
    transform: rotate(5deg);
}

.portrait-cloud-front {
    width: 180px;
    height: 110px;
    right: -18px;
    bottom: 16px;
    background: rgba(247, 245, 251, 0.82);
    border: 1px solid rgba(109, 67, 204, 0.08);
    border-radius: 48% 52% 50% 50% / 60% 45% 55% 40%;
    backdrop-filter: blur(9px);
}

.floating-card {
    position: absolute;
    z-index: 4;
    min-width: 190px;
    background: color-mix(in srgb, var(--surface) 92%, transparent);
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: var(--shadow-medium);
    backdrop-filter: blur(15px);
    padding: 15px 18px;
    transition:
        transform 0.22s ease,
        box-shadow 0.22s ease,
        border-color 0.22s ease;
}

.floating-card:hover {
    transform: translateY(-8px) scale(1.025);
    box-shadow: 0 24px 58px rgba(59, 37, 96, 0.17);
    border-color: color-mix(in srgb, var(--primary) 34%, var(--border));
}

.floating-card-top {
    top: 14%;
    right: -40px;
}

.floating-card-bottom {
    left: -45px;
    bottom: 12%;
}

.floating-card span {
    display: block;
    color: var(--text-faint);
    font-size: 0.7rem;
    font-weight: 750;
    letter-spacing: 0.1em;
    margin-bottom: 3px;
    text-transform: uppercase;
}

.floating-card strong {
    font-size: 0.88rem;
}

.scroll-indicator {
    position: absolute;
    left: 50%;
    bottom: 18px;
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 13px;
    color: var(--text-faint);
    font-size: 0.72rem;
    font-weight: 750;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    transform: translateX(-50%);
}

.scroll-line {
    position: relative;
    width: 55px;
    height: 1px;
    overflow: hidden;
    background: var(--border);
}

.scroll-line::after {
    position: absolute;
    inset: 0;
    background: var(--primary);
    content: "";
    animation: scrollLine 1.8s ease-in-out infinite;
    transform: translateX(-100%);
}

@keyframes scrollLine {
    50% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(100%);
    }
}


/* =========================================================
   7. ABOUT
   ========================================================= */

.about-section,
.projects-section {
    background: var(--background-secondary);
}

.about-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.65fr);
    gap: 72px;
    align-items: start;
}

.about-main {
    color: var(--text-soft);
    font-size: 1.03rem;
}

.about-title {
    max-width: 760px;
    color: var(--primary);
    font-size: clamp(2.25rem, 4.6vw, 4.1rem);
    font-weight: 760;
    letter-spacing: -0.035em;
    line-height: 1.06;
    margin-bottom: 15px;
}

.about-main .section-label {
    margin-top: 4px;
}

.about-main p {
    margin-bottom: 16px;
}

.about-main p:last-child {
    margin-bottom: 0;
}

.about-main .large-paragraph {
    color: var(--text-soft);
    font-size: clamp(1.45rem, 2.8vw, 2.25rem);
    font-weight: 400;
    letter-spacing: -0.035em;
    line-height: 1.35;
    margin-bottom: 15px;
}

.about-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
    border-top: 1px solid var(--border);
    margin-top: 90px;
}

.detail-item {
    position: relative;
    padding: 16px 14px;
    margin-inline: -14px;
    border-bottom: 1px solid var(--border);
    border-radius: 14px;
    transition:
        transform 0.25s ease,
        background 0.25s ease,
        box-shadow 0.25s ease;
}

.detail-item:hover {
    z-index: 2;
    background: var(--surface);
    box-shadow: 0 18px 45px rgba(66, 42, 108, 0.12);
    transform: translateX(10px) scale(1.025);
}

.detail-item span {
    display: block;
    color: var(--text-faint);
    font-size: 0.73rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    margin-bottom: 10px;
    text-transform: uppercase;
}

.detail-item strong {
    display: block;
    color: var(--text);
    font-size: 0.93rem;
    font-weight: 650;
    line-height: 1.45;
}

.statistics-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-top: 78px;
}

.statistic {
    min-height: 190px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background: var(--primary-light);
    border: 1px solid rgba(125, 90, 205, 0.18);
    border-radius: 20px;
    box-shadow: 0 16px 36px rgba(80, 54, 135, 0.12);
    padding: 28px;
    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease,
        background 0.3s ease;
}

.statistic:hover {
    background: var(--primary);
    box-shadow: 0 24px 60px rgba(63, 38, 108, 0.16);
    transform: translateY(-10px) scale(1.025);
}

.statistic strong {
    color: #ffffff;
    font-size: 3rem;
    line-height: 1;
}

.statistic span {
    max-width: 240px;
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.87rem;
}

body.dark-theme .statistic {
    background: var(--primary-light);
}

body.dark-theme .statistic strong,
body.dark-theme .statistic span {
    color: #17131f;
}

body.dark-theme .statistic:hover {
    background: var(--primary);
}


/* =========================================================
   8. EXPERIENCE TIMELINE
   ========================================================= */

.timeline {
    --timeline-x: 7px;
    position: relative;
    margin-left: 20px;
}

.timeline::before,
.timeline-progress {
    position: absolute;
    top: 0;
    left: var(--timeline-x);
    width: 3px;
    border-radius: 999px;
    transform: translateX(-50%);
}

.timeline::before {
    bottom: 0;
    background: color-mix(in srgb, var(--primary) 17%, var(--border));
    content: "";
}

.timeline-progress {
    z-index: 1;
    height: 0;
    background: linear-gradient(
        to bottom,
        var(--primary-light),
        var(--primary)
    );
    box-shadow:
        0 0 12px color-mix(in srgb, var(--primary) 60%, transparent),
        0 0 28px color-mix(in srgb, var(--primary) 28%, transparent);
    pointer-events: none;
}

.timeline-item {
    position: relative;
    display: grid;
    grid-template-columns: 160px minmax(0, 1fr);
    gap: 36px;
    padding: 0 0 55px 42px;
}

.timeline-marker {
    position: absolute;
    top: 8px;
    left: var(--timeline-x);
    z-index: 3;
    width: 15px;
    height: 15px;
    background: var(--background);
    border: 4px solid var(--primary);
    border-radius: 50%;
    box-shadow: 0 0 0 7px color-mix(in srgb, var(--primary) 10%, transparent);
    transform: translateX(-50%);
    transition:
        background 0.3s ease,
        border-color 0.3s ease,
        box-shadow 0.3s ease,
        transform 0.3s ease;
}

.timeline-item.timeline-reached .timeline-marker {
    background: var(--primary);
    border-color: var(--surface);
    box-shadow:
        0 0 0 7px color-mix(in srgb, var(--primary) 15%, transparent),
        0 0 22px color-mix(in srgb, var(--primary) 58%, transparent);
    transform: translateX(-50%) scale(1.12);
}

.timeline-date {
    color: var(--text-faint);
    font-size: 0.84rem;
    font-weight: 750;
    padding-top: 5px;
}

.timeline-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 22px;
    padding: 28px;
    transition:
        transform 0.28s ease,
        box-shadow 0.28s ease,
        border-color 0.28s ease;
}

.timeline-card:hover {
    border-color: color-mix(in srgb, var(--primary) 40%, var(--border));
    box-shadow: var(--shadow-medium);
    transform: translateY(-6px);
}

.timeline-card-header {
    display: flex;
    justify-content: space-between;
    gap: 20px;
}

.timeline-card-header h3 {
    font-size: 1.45rem;
}

.timeline-card-header p {
    color: var(--primary);
    font-size: 0.9rem;
    font-weight: 700;
    margin-top: 3px;
}

.timeline-card-header > span {
    height: fit-content;
    background: var(--surface-soft);
    border-radius: 999px;
    color: var(--primary);
    font-size: 0.72rem;
    font-weight: 750;
    padding: 7px 11px;
}

.timeline-card > p {
    color: var(--text-soft);
    margin-top: 18px;
}

.technology-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 22px;
}

.technology-list span {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 999px;
    color: var(--text-soft);
    cursor: default;
    font-size: 0.74rem;
    font-weight: 700;
    padding: 7px 11px;
    transition:
        transform 0.2s ease,
        background 0.2s ease,
        color 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.technology-list span:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
    box-shadow: 0 9px 22px color-mix(in srgb, var(--primary) 24%, transparent);
    transform: translateY(-4px);
}


/* =========================================================
   9. PROJECT ACCORDION
   ========================================================= */

.project-accordion {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.project-panel {
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 24px;
    box-shadow: var(--shadow-soft);
    transition:
        border-color 0.3s ease,
        box-shadow 0.3s ease;
}

.project-panel:hover,
.project-panel.is-active {
    border-color: color-mix(in srgb, var(--primary) 38%, var(--border));
    box-shadow: var(--shadow-medium);
}

.project-toggle {
    width: 100%;
    min-height: 108px;
    display: grid;
    grid-template-columns: minmax(260px, 1fr) minmax(420px, auto);
    gap: 30px;
    align-items: center;
    background: transparent;
    border: 0;
    cursor: pointer;
    padding: 23px 28px;
    text-align: left;
}

.project-title {
    color: var(--text);
    font-size: clamp(1.3rem, 2.5vw, 2.15rem);
    font-weight: 720;
    letter-spacing: -0.035em;
    line-height: 1.1;
}

.project-compact-meta {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 38px;
    gap: 22px;
    align-items: center;
}

.project-tech-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.project-tech-list span {
    background: var(--surface-soft);
    border: 1px solid var(--border);
    border-radius: 999px;
    color: var(--text-soft);
    font-size: 0.72rem;
    font-weight: 720;
    padding: 7px 11px;
    transition:
        background 0.2s ease,
        border-color 0.2s ease,
        color 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.project-tech-list span:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
    box-shadow: 0 9px 22px color-mix(in srgb, var(--primary) 24%, transparent);
    transform: translateY(-3px);
}

.project-open-icon {
    position: relative;
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    background: var(--surface-soft);
    border: 1px solid var(--border);
    border-radius: 14px;
    color: var(--primary);
    font-size: 0;
    line-height: 1;
    transition:
        background 0.3s ease,
        border-color 0.3s ease,
        color 0.3s ease;
}

.project-open-icon::before,
.project-open-icon::after {
    position: absolute;
    top: 50%;
    left: 50%;
    background: currentColor;
    border-radius: 999px;
    content: "";
    transform: translate(-50%, -50%);
}

.project-open-icon::before {
    width: 10px;
    height: 2px;
}

.project-open-icon::after {
    width: 2px;
    height: 10px;
    transition: opacity 0.3s ease;
}

.project-panel.is-active .project-open-icon {
    background: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
}

.project-panel.is-active .project-open-icon::after {
    opacity: 0;
}

body.dark-theme .project-panel.is-active .project-open-icon {
    color: #111111;
}

.project-expanded-content {
    display: grid;
    grid-template-columns: minmax(320px, 0.95fr) minmax(0, 1.05fr);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition:
        max-height 0.65s cubic-bezier(0.2, 0.8, 0.2, 1),
        opacity 0.35s ease;
}

.project-panel.is-active .project-expanded-content {
    max-height: 760px;
    opacity: 1;
}

.project-image-area {
    position: relative;
    min-height: 390px;
    overflow: hidden;
    background-color: var(--primary);
    background-image:
        linear-gradient(
            180deg,
            rgba(18, 12, 27, 0.05),
            rgba(18, 12, 27, 0.78)
        ),
        var(--project-image);
    background-position: center;
    background-size: cover;
    border-radius: 20px;
    margin: 0 0 26px 26px;
    transform: scale(0.97);
    transition: transform 0.55s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.project-panel.is-active .project-image-area {
    transform: scale(1);
}

.project-image-area::before {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(125, 90, 205, 0.25),
        transparent 54%
    );
    content: "";
}

.project-image-overlay {
    position: absolute;
    inset: auto 0 0;
    z-index: 2;
    color: #ffffff;
    padding: 32px;
}

.project-category {
    font-size: 0.72rem;
    font-weight: 820;
    letter-spacing: 0.16em;
    margin-bottom: 7px;
    text-transform: uppercase;
}

.project-short-label {
    max-width: 420px;
    font-size: clamp(1.5rem, 3vw, 2.6rem);
    font-weight: 680;
    letter-spacing: -0.04em;
    line-height: 1.08;
}

.project-description-area {
    min-height: 390px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 42px 46px 48px;
}

.project-description-area > p {
    max-width: 620px;
    color: var(--text-soft);
    font-size: clamp(1rem, 1.7vw, 1.2rem);
    line-height: 1.75;
}

.project-repository-link {
    width: fit-content;
    display: inline-flex;
    align-items: center;
    gap: 11px;
    color: var(--primary);
    font-size: 0.9rem;
    font-weight: 820;
    margin-top: 32px;
}

.project-repository-link span {
    transition: transform 0.2s ease;
}

.project-repository-link:hover span {
    transform: translate(4px, -4px);
}


/* =========================================================
   10. SKILLS
   ========================================================= */

.skills-introduction {
    max-width: 960px;
    color: var(--text-soft);
    font-size: 1.02rem;
    margin: -24px 0 40px 50px;
}

.skill-system {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-left: 50px;
}

.skill-family {
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 24px;
    box-shadow: var(--shadow-soft);
    transition:
        border-color 0.25s ease,
        box-shadow 0.25s ease;
}

.skill-family:hover {
    border-color: color-mix(in srgb, var(--primary) 35%, var(--border));
    box-shadow: var(--shadow-medium);
}

.skill-family-heading {
    width: 100%;
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr) 36px;
    gap: 14px;
    align-items: center;
    background: transparent;
    border: 0;
    cursor: pointer;
    text-align: left;
    padding: 18px 24px;
}

.skill-family-number {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    background: var(--surface-soft);
    border-radius: 14px;
    color: var(--primary);
    font-size: 0.78rem;
    font-weight: 850;
}

.skill-family-heading strong {
    display: block;
    font-size: 1.12rem;
    line-height: 1.2;
}

.skill-family-heading small {
    display: block;
    color: var(--text-faint);
    font-size: 0.78rem;
    font-weight: 550;
    line-height: 1.35;
    margin-top: 2px;
}

.family-toggle {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    background: var(--surface-soft);
    border-radius: 12px;
    color: var(--primary);
    font-size: 1.15rem;
    font-weight: 700;
    justify-self: end;
}

.skill-family-content {
    display: grid;
    grid-template-rows: 1fr;
    transition:
        grid-template-rows 0.35s ease,
        opacity 0.3s ease;
}

.skill-family.collapsed .skill-family-content {
    grid-template-rows: 0fr;
    opacity: 0;
}

.skill-family-content > * {
    min-height: 0;
}

.skill-cluster {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 2px 24px 22px 86px;
}

.skill-chip {
    position: relative;
    background: var(--surface-soft);
    border: 1px solid var(--border);
    border-radius: 999px;
    color: var(--text-soft);
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 750;
    padding: 9px 14px;
    opacity: 0.2;
    transform:
        translate(
            var(--skill-start-x, 0),
            var(--skill-start-y, 24px)
        )
        scale(0.88);
    transition:
        transform 0.75s cubic-bezier(0.2, 0.8, 0.2, 1),
        opacity 0.6s ease,
        background 0.2s ease,
        color 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
    transition-delay: var(--skill-delay, 0ms);
}

.skill-family.skills-settled .skill-chip {
    opacity: 1;
    transform: translate(0, 0) scale(1);
}

.skill-chip:hover,
.skill-chip.active {
    z-index: 3;
    background: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
    box-shadow: 0 11px 26px color-mix(in srgb, var(--primary) 25%, transparent);
    transform: translateY(-4px) scale(1.035);
}


/* =========================================================
   11. SKILL MODAL
   ========================================================= */

.skill-modal {
    position: fixed;
    inset: 0;
    z-index: 1500;
    display: grid;
    place-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.skill-modal.open {
    opacity: 1;
    pointer-events: auto;
}

.skill-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(20, 13, 30, 0.55);
    border: 0;
    cursor: pointer;
    backdrop-filter: blur(8px);
}

.skill-modal-card {
    position: relative;
    z-index: 2;
    width: min(92%, 580px);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 26px;
    box-shadow: var(--shadow-strong);
    padding: 34px;
    transform: translateY(18px) scale(0.97);
    transition: transform 0.28s ease;
}

.skill-modal.open .skill-modal-card {
    transform: translateY(0) scale(1);
}

.skill-modal-close {
    position: absolute;
    top: 18px;
    right: 18px;
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    background: var(--surface-soft);
    border: 1px solid var(--border);
    border-radius: 14px;
    color: var(--primary);
    cursor: pointer;
    font-size: 0;
    line-height: 1;
    padding: 0;
}

.skill-modal-close::before,
.skill-modal-close::after {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 17px;
    height: 2.5px;
    background: currentColor;
    border-radius: 999px;
    content: "";
}

.skill-modal-close::before {
    transform: translate(-50%, -50%) rotate(45deg);
}

.skill-modal-close::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

.skill-modal-close:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
}

body.dark-theme .skill-modal-close {
    background: var(--surface-soft);
    color: var(--primary-light);
}

body.dark-theme .skill-modal-close:hover {
    background: var(--primary);
    color: #111111;
}

.skill-modal-label {
    color: var(--primary);
    font-size: 0.73rem;
    font-weight: 850;
    letter-spacing: 0.13em;
    text-transform: uppercase;
}

.skill-modal-card h3 {
    font-size: clamp(2rem, 5vw, 3rem);
    margin: 12px 0 14px;
}

.skill-modal-card > p:not(.skill-modal-label) {
    color: var(--text-soft);
}

.skill-modal-source {
    background: var(--surface-soft);
    border-radius: 17px;
    margin-top: 25px;
    padding: 18px;
}

.skill-modal-source span {
    display: block;
    color: var(--primary);
    font-size: 0.7rem;
    font-weight: 850;
    letter-spacing: 0.1em;
    margin-bottom: 6px;
    text-transform: uppercase;
}

.skill-modal-source p {
    color: var(--text-soft);
}


/* =========================================================
   12. CONTACT
   ========================================================= */

.contact-section {
    position: relative;
    overflow: hidden;
    background: var(--primary);
    color: #ffffff;
    padding: 90px 0;
}

.contact-section::before {
    position: absolute;
    top: -170px;
    left: -90px;
    width: 520px;
    height: 420px;
    background: radial-gradient(
        circle at 30% 30%,
        rgba(226, 211, 251, 0.32),
        rgba(180, 145, 234, 0.12) 42%,
        transparent 72%
    );
    content: "";
    filter: blur(8px);
    pointer-events: none;
}

.contact-content {
    position: relative;
    z-index: 2;
    width: min(92%, 1120px);
    text-align: center;
}

.contact-content .section-label {
    color: #e6dcf8;
}

.contact-content h2 {
    max-width: 1040px;
    font-size: clamp(3rem, 6vw, 6rem);
    letter-spacing: 0.001em;
    line-height: 0.98;
    margin: 0 auto 28px;
}

.contact-content > p:not(.section-label) {
    max-width: 880px;
    color: #eee7fb;
    margin: 0 auto 34px;
}

.contact-button {
    background: #ffffff;
    color: var(--primary);
}

.contact-links {
    display: flex;
    justify-content: center;
    gap: 28px;
    margin-top: 44px;
}

.contact-links a {
    color: #eee7fb;
    font-size: 0.88rem;
    font-weight: 650;
}

.contact-links a:hover {
    color: #ffffff;
}


/* =========================================================
   13. FOOTER
   ========================================================= */

.site-footer {
    background: #171020;
    color: #aaa0b6;
    padding: 27px 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    gap: 30px;
    font-size: 0.82rem;
}


/* =========================================================
   14. REVEAL ANIMATION
   ========================================================= */

.reveal {
    opacity: 0;
    transform: translateY(25px);
    transition: opacity 0.75s ease, transform 0.75s ease;
}

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


/* =========================================================
   15. TABLET
   ========================================================= */

@media (max-width: 980px) {
    .section {
        padding: 92px 0;
    }

    .site-header {
        top: 10px;
    }

    .header-shell {
        border-radius: 22px;
    }

    .hero-section {
        padding-top: calc(var(--header-height) + 48px);
    }

    .hero-grid,
    .about-layout {
        grid-template-columns: 1fr;
    }

    .hero-grid {
        gap: 54px;
    }

    .hero-visual {
        max-width: 540px;
        justify-self: center;
    }

    .hero-cloud-one {
        right: -18%;
    }

    .hero-cloud-two {
        right: 3%;
    }

    .about-layout {
        gap: 42px;
    }

    .about-details {
        margin-top: 0;
    }

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

    .project-toggle {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .project-compact-meta {
        grid-template-columns: minmax(0, 1fr) 38px;
    }

    .project-tech-list {
        justify-content: flex-start;
    }

    .project-expanded-content {
        grid-template-columns: 1fr;
    }

    .project-panel.is-active .project-expanded-content {
        max-height: 1100px;
    }

    .project-image-area {
        min-height: 330px;
        margin: 0 22px;
    }

    .project-description-area {
        min-height: auto;
        padding: 30px 28px 36px;
    }

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


/* =========================================================
   16. MOBILE
   ========================================================= */

@media (max-width: 760px) {
    :root {
        --header-height: 64px;
    }

    .section {
        padding: 76px 0;
    }

    .header-shell {
        width: min(94%, var(--container-width));
        border-radius: 20px;
    }

    .navbar {
        padding: 0 10px;
    }

    .desktop-navigation {
        display: none;
    }

    .menu-button {
        display: grid;
    }

    .mobile-navigation {
        position: fixed;
        inset: calc(var(--header-height) + 22px) 3% 3%;
        z-index: 1;
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 22px;
        background: var(--background-secondary);
        border: 1px solid var(--border);
        border-radius: 24px;
        box-shadow: var(--shadow-strong);
        opacity: 0;
        padding: 30px 8%;
        pointer-events: none;
        transform: translateY(-15px);
        transition: opacity 0.25s ease, transform 0.25s ease;
    }

    .mobile-navigation.open {
        opacity: 1;
        pointer-events: auto;
        transform: translateY(0);
    }

    .mobile-navigation a {
        color: var(--text);
        font-size: 2rem;
        font-weight: 700;
    }

    body.dark-theme .theme-button,
    body.dark-theme .menu-button {
        background: var(--surface-soft);
        color: var(--text);
    }

    body.dark-theme .menu-button span {
        background: var(--text);
    }

    body.dark-theme .mobile-navigation {
        background: var(--background-secondary);
    }

    body.dark-theme .mobile-navigation a {
        color: var(--text);
    }

    .section-heading {
        grid-template-columns: 1fr;
        gap: 8px;
        margin-bottom: 50px;
    }

    .hero-section {
        padding-top: calc(var(--header-height) + 58px);
    }

    .hero-visual {
        padding-top: 82px;
    }

    .floating-card {
        min-width: 0;
        max-width: 170px;
        padding: 12px 14px;
    }

    .floating-card-top {
        top: 10px;
        right: 4px;
        left: auto;
    }

    .floating-card-bottom {
        left: 4px;
        bottom: 12px;
    }

    .hero-socials {
        justify-content: flex-start;
        padding-left: 0;
    }

    .scroll-indicator {
        display: none;
    }

    .timeline-item {
        grid-template-columns: 1fr;
        gap: 12px;
        padding-left: 38px;
    }

    .timeline-card-header {
        flex-direction: column;
    }

    .skills-introduction,
    .skill-system {
        width: 100%;
        max-width: none;
        margin-left: 0;
        margin-right: 0;
    }

    .skills-introduction {
        margin-top: -12px;
        margin-bottom: 30px;
    }

    .skill-family-heading {
        grid-template-columns: 42px minmax(0, 1fr) 34px;
        gap: 12px;
        padding: 16px;
    }

    .skill-family-number {
        width: 40px;
        height: 40px;
    }

    .skill-family-heading strong {
        font-size: 1rem;
    }

    .skill-family-heading small {
        font-size: 0.74rem;
    }

    .family-toggle {
        width: 34px;
        height: 34px;
    }

    .skill-cluster {
        width: 100%;
        padding: 0 16px 18px;
    }

    .project-toggle {
        padding: 21px 20px;
    }

    .project-compact-meta {
        grid-template-columns: minmax(0, 1fr) 38px;
        gap: 14px;
    }

    .project-tech-list {
        max-width: 100%;
    }

    .project-image-area {
        min-height: 280px;
        border-radius: 17px;
        margin: 0 14px;
    }

    .project-image-overlay {
        padding: 24px;
    }

    .contact-section {
        padding: 70px 0;
    }
}


/* =========================================================
   17. SMALL MOBILE
   ========================================================= */

@media (max-width: 520px) {
    .hero-content h1 {
        font-size: clamp(3.3rem, 16vw, 5.2rem);
    }

    .hero-actions {
        flex-direction: column;
    }

    .hero-actions .button {
        width: 100%;
    }

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

    .floating-card-top {
        top: 12px;
        right: 4px;
    }

    .floating-card-bottom {
        left: 4px;
        bottom: 12px;
    }

    .about-title {
        font-size: clamp(2.1rem, 11vw, 3.3rem);
    }

    .about-main .large-paragraph {
        font-size: clamp(1.3rem, 7vw, 1.8rem);
    }

    .skill-modal-card {
        width: calc(100% - 28px);
        max-height: calc(100vh - 28px);
        overflow-y: auto;
        border-radius: 22px;
        padding: 70px 22px 26px;
    }

    .skill-modal-close {
        top: 16px;
        right: 16px;
        width: 40px;
        height: 40px;
    }

    .skill-modal-card h3 {
        font-size: clamp(1.8rem, 10vw, 2.5rem);
        overflow-wrap: anywhere;
    }

    .contact-links,
    .footer-content {
        flex-wrap: wrap;
        justify-content: center;
        text-align: center;
    }
}


/* =========================================================
   18. REDUCED MOTION
   ========================================================= */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}
