:root {
    --bg: #1A1618;
    --card-bg: rgba(45, 36, 39, 0.7);
    --text: #EDE3DF;
    --accent-1: #EBACC7;
    --accent-2: #DD598A;
    --accent-3: #EDE3DF;
    --dim-text: rgba(237, 227, 223, 0.8);
    
    --sans: 'Lexend', sans-serif;
    --mono: 'JetBrains Mono', monospace;
}

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

html {
    scroll-snap-type: y mandatory;
    scroll-behavior: smooth;
}

body {
    background-color: #0F0D0E;
    color: var(--text);
    font-family: var(--sans);
    line-height: 1.6;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

::selection {
    background: var(--accent-2);
    color: var(--bg);
}

/* Scroll Progress Bar */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 4px;
    background: var(--accent-2);
    width: 0%;
    z-index: 10001;
    box-shadow: 0 0 15px var(--accent-2), 0 0 5px var(--accent-1);
}

body::before, body::after {
    content: '';
    position: fixed;
    width: 120vmax;
    height: 120vmax;
    border-radius: 50%;
    z-index: -1;
    pointer-events: none;
    filter: blur(120px);
    opacity: 0.07;
}

body::before {
    top: calc(-20vmax + (var(--m-y, 0) * 120px));
    left: calc(-20vmax + (var(--m-x, 0) * 120px));
    background: radial-gradient(circle, var(--accent-2) 0%, transparent 70%);
    animation: blob-float 35s infinite alternate ease-in-out;
}

body::after {
    display: block;
    bottom: calc(-20vmax - (var(--m-y, 0) * 120px));
    right: calc(-20vmax - (var(--m-x, 0) * 120px));
    background: radial-gradient(circle, var(--accent-1) 0%, transparent 70%);
    animation: blob-float 25s infinite alternate-reverse ease-in-out;
    animation-delay: -12s;
}

@keyframes blob-float {
    0% { transform: translate(0, 0) rotate(0deg) scale(1); }
    100% { transform: translate(15vw, 15vh) rotate(10deg) scale(1.1); }
}

.noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.06;
    z-index: 1000;
    pointer-events: none;
    mix-blend-mode: soft-light;
}

/* Loader */
.loader-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease;
}

.loader-content {
    text-align: center;
}

.cat-loader {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--accent-1);
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 2rem;
}

.container-inner {
    max-width: 900px;
    margin: 0 auto;
    width: 100%;
}

header {
    background: #0A090A;
    padding: 0 2rem;
    border-bottom: 1px solid rgba(235, 172, 199, 0.05);
    height: 80px;
    display: flex;
    align-items: center;
}

header .container-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

@keyframes gradient-shift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

header .logo pre.cat-logo {
    color: var(--text);
    font-size: 0.8rem;
    line-height: 1;
    margin: 0 1.5rem 0 0;
    font-weight: bold;
    transform: none;
    display: inline-block;
    opacity: 0.7;
}

header .logo {
    display: flex;
    align-items: center;
}

.brand-dev {
    color: var(--accent-2);
    font-weight: 800;
}

header .brand-dev {
    color: var(--accent-2);
}

header .logo h1 {
    font-family: var(--mono);
    font-size: 2.2rem;
    color: var(--text);
    font-weight: 400;
    letter-spacing: -1px;
}

header nav ul {
    list-style: none;
    display: flex;
    gap: 1.5rem;
}

header nav a {
    color: var(--text);
    text-decoration: none;
    font-family: var(--mono);
    font-size: 1rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border: 2px solid var(--text);
    transition: all 0.2s ease;
}

header nav a:hover {
    background: var(--bg);
    color: var(--accent-1);
    transform: translateY(-3px);
}

.mono {
    font-family: var(--mono);
}

/* Sections & Layouts */
section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 4rem 0;
    opacity: 0;
    transform: translateY(30px);
    transition: all 1s cubic-bezier(0.2, 0.8, 0.2, 1);
    scroll-snap-align: start;
    position: relative;
}

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

.section-label {
    font-size: 0.8rem;
    letter-spacing: 2px;
    color: var(--accent-1);
    margin-bottom: 2rem;
    opacity: 0.6;
    text-transform: lowercase;
}

/* Hero Section */
.hero-section {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-top: 0;
    min-height: calc(100vh - 80px);
    scroll-snap-align: start;
    scroll-margin-top: 80px;
}

.slogan-main {
    font-size: clamp(2.5rem, 8vw, 5rem);
    line-height: 1.1;
    letter-spacing: -1.5px;
    max-width: 850px;
    margin-bottom: 2rem;
    color: var(--text);
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.slogan-line {
    position: relative;
    width: fit-content;
    overflow: hidden;
    display: block;
}

.slogan-line::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 100%;
    background: var(--accent-2);
    z-index: 2;
    pointer-events: none;
}

.slogan-line.reveal-anim::after {
    animation: slide-reveal 1.2s cubic-bezier(0.77, 0, 0.175, 1) forwards;
}

@keyframes slide-reveal {
    0% { width: 0%; left: 0; }
    50% { width: 100%; left: 0; }
    100% { width: 0%; left: 100%; }
}

.hero-subline {
    max-width: 600px;
    margin-top: 1rem;
    font-size: 1.2rem;
    color: var(--dim-text);
    opacity: 0.8;
}


.scroll-hint {
    margin-top: 4rem;
    font-size: 0.9rem;
    opacity: 0.4;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {transform: translateY(0);}
    40% {transform: translateY(-10px);}
    60% {transform: translateY(-5px);}
}

/* Split Section (About, ...) */
.split-content {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
    align-items: center;
}

.large-text {
    font-size: 2.5rem;
    line-height: 1.2;
    margin-bottom: 2rem;
    font-family: var(--mono);
    color: var(--accent-3);
}

.text-block p + p {
    margin-top: 1.5rem;
    font-size: 1.3rem;
    max-width: 90%;
}

.paws-list {
    margin-top: 3rem;
    display: none;
}

.paws-list span {
    background: rgba(235, 172, 199, 0.1);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    border: 1px solid rgba(235, 172, 199, 0.2);
}


.tags-cloud {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100vw;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
}

.tag-badge {
    position: absolute;
    padding: 0.6rem 1.2rem;
    background: var(--card-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(235, 172, 199, 0.2);
    border-radius: 16px;
    color: var(--accent-1);
    font-size: 0.9rem;
    transition: all 0.3s ease;
    cursor: default;
    z-index: -1;
    pointer-events: none;
    white-space: nowrap;
    opacity: 0.3;
    animation: tag-float 15s infinite alternate ease-in-out;
}

@keyframes tag-float {
    0% { transform: translate(0, 0) rotate(0deg); }
    100% { transform: translate(20px, 20px) rotate(5deg); }
}

.tag-badge:nth-child(even) {
    animation-duration: 20s;
    animation-delay: -5s;
}

.tag-badge:nth-child(3n) {
    animation-duration: 18s;
    animation-delay: -2s;
}

.tag-badge:hover {
    opacity: 0.8;
    z-index: 10;
}

.about-cat {
    color: var(--accent-1);
    font-size: 0.8rem;
    line-height: 1.2;
}

/* List Section (Projects) */
.project-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 0 4rem;
}

.project-entry {
    display: flex;
    align-items: flex-start;
    padding: 3rem 0;
    border-bottom: 1px solid rgba(235, 172, 199, 0.15);
    transition: all 0.4s ease;
    cursor: pointer;
    position: relative;
    text-decoration: none;
    color: inherit;
}

.project-num {
    font-size: 1rem;
    margin-right: 3rem;
    margin-top: 0.5rem;
    opacity: 0.3;
}

.project-info {
    flex: 1;
}

.project-info h4 {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
    transition: color 0.3s ease;
}

.project-tag {
    font-size: 0.8rem;
    padding: 0.4rem 0.8rem;
    border: 1px solid var(--accent-2);
    color: var(--accent-2);
    border-radius: 100px;
    margin-left: 2rem;
}

.project-entry:hover {
    border-bottom-color: var(--accent-2);
}

.project-entry:hover h4 {
    color: var(--accent-1);
}

/* Focus Section (Contact) */
.contact-wrap {
    text-align: center;
    padding: 4rem 0;
}

.contact-wrap h3 {
    font-size: clamp(3rem, 12vw, 6rem);
    margin-bottom: 1rem;
    color: var(--text);
    display: inline-block;
}

.contact-wrap h3::after {
    display: none;
}

.social-links-new {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 2rem;
    margin-top: 4rem;
    padding: 2rem 0;
}

.social-item {
    position: relative;
    text-decoration: none;
    color: var(--accent-1);
    font-size: 1.05rem;
    padding: 0.6rem 1.4rem;
    margin: 0.5rem;
    transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
    background: var(--card-bg);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(235, 172, 199, 0.1);
    border-radius: 12px;
    line-height: 1;
}

.social-item span {
    position: relative;
    z-index: 2;
}

.item-blur {
    position: absolute;
    inset: -5px;
    background: var(--accent-2);
    filter: blur(20px);
    opacity: 0;
    z-index: 0;
    transition: opacity 0.4s ease;
    border-radius: 12px;
    pointer-events: none;
}

.social-item:hover {
    color: var(--text);
    transform: translateY(-5px);
    border-color: var(--accent-2);
    background: rgba(221, 89, 138, 0.1);
}

.social-item:hover .item-blur {
    opacity: 0.3;
}

/* Mobile Adjustments */
@media (max-width: 900px) {
    .split-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .large-text {
        font-size: 2rem;
    }

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

    .project-entry {
        flex-direction: column;
    }

    .project-num {
        margin-bottom: 1rem;
    }

    .project-tag {
        margin-left: 0;
        margin-top: 1rem;
        display: inline-block;
    }

    .social-links-new {
        flex-direction: column;
        gap: 1rem;
    }
}

@media (max-width: 600px) {
    section {
        padding: 6rem 0;
    }
    
    .hero-section {
        min-height: 100vh;
    }
}

footer {
    background: #0A090A;
    color: var(--text);
    padding: 4rem 2rem 3rem;
    border-top: 1px solid rgba(235, 172, 199, 0.05);
    scroll-snap-align: start;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    margin-bottom: 3rem;
}

.footer-leaderboard {
    display: flex;
    justify-content: flex-end;
    width: 100%;
}

.footer-leaderboard iframe {
    display: block;
    max-width: 100%;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-links a {
    color: var(--accent-1);
    text-decoration: none;
    font-weight: 400;
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: var(--text);
    text-decoration: none;
}


.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid rgba(235, 172, 199, 0.1);
    text-align: center;
}

.footer-bottom p {
    color: var(--dim-text);
    font-weight: 400;
    font-size: 0.9rem;
}

@media (max-width: 600px) {
    header {
        padding: 1rem;
        height: auto;
        min-height: 80px;
    }

    header .container-inner {
        flex-direction: row;
        align-items: center;
        gap: 1rem;
    }
    
    header nav ul {
        gap: 0.8rem;
    }

    header .logo h1 {
        font-size: 1.4rem;
    }

    header .logo pre.cat-logo {
        display: none;
    }

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

    .footer-leaderboard {
        justify-content: flex-start;
    }

    h2 {
        font-size: 2rem;
    }
}
