/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Caveat:wght@400;500;600;700&display=swap');

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Gilroy', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: #000;
    background-color: #f4f0e7;
    overflow-x: hidden;
}

/* Dog Page (formerly loading screen) */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #f4f0e7;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    overflow: hidden;
}

.hero-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: calc(var(--hero-nav-height, 70px) + 24px) clamp(16px, 4vw, 40px) clamp(24px, 6vh, 64px);
    box-sizing: border-box;
    overflow: hidden;
}

.hero-scale {
    position: relative;
    width: 1440px;
    height: 900px;
    transform-origin: center center;
    transform: scale(var(--hero-scale, 1));
}

/* Landing Page Navigation */
.landing-nav {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(244, 240, 231, 0.95);
    backdrop-filter: blur(10px);
    z-index: 10000;
    transition: all 0.3s ease;
}

.landing-nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    height: 70px;
}

.landing-nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: 'Chelsea Market', cursive;
    font-weight: 400;
    font-size: 18px;
    color: #000;
}

.landing-logo-img {
    width: 50px;
    height: 50px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.landing-logo-img:hover {
    transform: scale(1.05);
}

.landing-logo-text {
    font-family: 'Chelsea Market', cursive;
    font-weight: 400;
    font-size: 18px;
    color: #000;
}

/* Dog and Cards Container */
.dog-cards-container {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    z-index: 10;
}

/* Dog in center with entrance animation */
.loading-screen .dog {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) scale(0);
    width: 180px;
    height: 210px;
    z-index: 10;
    animation: dogAppear 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) 0.3s forwards;
}

@keyframes dogAppear {
    from {
        transform: translate(-50%, -50%) scale(0);
        opacity: 0;
    }
    to {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
}

/* Intro text below dog */
.loading-screen .intro {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(50% + 160px);
    text-align: center;
    max-width: 665px;
    margin: 0 auto;
    padding: 0 20px;
    z-index: 11;
    opacity: 0;
    animation: fadeInUp 0.5s ease-out 1.2s forwards;
}

.loading-screen .intro h2 {
    font-size: clamp(2.2rem, 4vw, 2.8rem);
    font-weight: 700;
    color: #2b2b2b;
    margin: 0;
    font-family: 'Caveat', cursive;
    border-right: 2px solid #2b2b2b;
    white-space: nowrap;
    line-height: 1.2;
    position: relative;
}

.loading-screen .intro-line1 {
    opacity: 1;
    animation: typewriter-fixed 4s steps(50, end) 1s forwards, hide-caret 0.01s 4.5s forwards;
}

.loading-screen .intro-line2 {
    font-size: clamp(0.9rem, 2vw, 1rem);
    color: #555;
    margin: 0.8rem 0 0 0;
    font-family: "Courier New", monospace;
    line-height: 1.5;
    opacity: 0;
    border-right: 2px solid #555;
    white-space: nowrap;
    overflow: hidden;
    animation: typewriter-fixed 2.5s steps(40, end) 4.6s forwards, hide-caret 0.01s 6.5s forwards;
}

.loading-screen .intro-line3 {
    font-size: clamp(0.9rem, 2vw, 1rem);
    color: #555;
    margin: 0;
    font-family: "Courier New", monospace;
    line-height: 1.5;
    opacity: 0;
    border-right: 2px solid #555;
    white-space: nowrap;
    overflow: hidden;
    animation: typewriter-fixed 2s steps(25, end) 6.6s forwards, hide-caret 0.01s 8.5s forwards;
}

@keyframes slideUpReveal {
    from {
        opacity: 0;
        transform: translateY(20px);
        clip-path: inset(100% 0 0 0);
    }
    to {
        opacity: 1;
        transform: translateY(0);
        clip-path: inset(0 0 0 0);
    }
}

/* Typewriter animations */
@keyframes typewriter {
    from {
        width: 0;
        opacity: 1;
    }
    to {
        width: 100%;
        opacity: 1;
    }
}

@keyframes typewriter-fixed {
    from {
        clip-path: inset(0 100% 0 0);
        opacity: 1;
    }
    to {
        clip-path: inset(0 0% 0 0);
        opacity: 1;
    }
}

@keyframes typewriter2 {
    from {
        width: 0;
        opacity: 1;
    }
    to {
        width: 100%;
        opacity: 1;
    }
}

@keyframes blink-caret {
    from, to {
        border-color: transparent;
    }
    50% {
        border-color: #2b2b2b;
    }
}

@keyframes blink-caret2 {
    from, to {
        border-color: transparent;
    }
    50% {
        border-color: #555;
    }
}

@keyframes hide-caret {
    to {
        border-color: transparent;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 头（固定） */
.head {
    position: absolute;
    top: 8px;
    left: 50%;
    width: 116px;
    height: 102px;
    transform: translateX(-50%);
    background: #E4B872;
    border-radius: 60px;
    z-index: 2;
    box-shadow: inset 0 0 2px rgba(255,255,255,0.3), 0 1px 2px rgba(0,0,0,0.1);
    animation: idle 2.2s ease-in-out infinite;
}

/* 垂耳 */
.ear {
    position: absolute;
    top: 22px;
    width: 42px;
    height: 74px;
    background: #C9964B;
    border-radius: 24px;
    transform-origin: top center;
    box-shadow: inset 0 -4px 0 rgba(0,0,0,.06);
    animation: earSwing 2.4s ease-in-out infinite, idle 2.2s ease-in-out infinite;
    z-index: 1;
}

.ear.left {
    left: 20px;
}

.ear.right {
    right: 20px;
}

/* 眼睛 & 瞳孔（只动瞳孔） */
.eye {
    position: absolute;
    top: 30px;
    width: 22px;
    height: 25px;
    background: #F1E5CC;
    border-radius: 50%;
    overflow: hidden;
}

.eye.left {
    left: 26px;
}

.eye.right {
    right: 26px;
}

.pupil {
    position: absolute;
    top: 33%;
    left: 50%;
    width: 12px;
    height: 12px;
    background: #222;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: transform 0.05s ease-out;
    transform-origin: center;
    will-change: transform;
}

/* 嘴口 + 鼻子 */
.snout {
    position: absolute;
    left: 50%;
    bottom: 10px;
    width: 64px;
    height: 48px;
    background: #F1E5CC;
    border-radius: 28px;
    transform: translateX(-50%);
}

.nose {
    position: absolute;
    left: 50%;
    top: 8px;
    width: 18px;
    height: 12px;
    border-radius: 8px;
    background: #333;
    transform: translateX(-50%);
    animation: sniff 1.6s ease-in-out infinite;
}

/* 身体 */
.body {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 140px;
    height: 108px;
    background: #D9A85E;
    border-radius: 72px 72px 50px 50px;
    z-index: 1; /* ✅ 身体在上 */
    animation: idle 2.2s ease-in-out infinite;
}

/* 尾巴在身体后面 */
.tail {
    position: absolute;
    right: -16px;
    bottom: 32px;
    width: 55px;
    height: 18px;
    background: linear-gradient(90deg, #d7a85b 0%, #b9823c 90%);
    border-radius: 14px 20px 20px 14px;
    transform-origin: left center;
    animation: wag 1.6s ease-in-out infinite, idle 2.2s ease-in-out infinite;
    z-index: 0; /* 确保在身体后面 */
    box-shadow: inset 0 0 2px rgba(255,255,255,0.3), 0 1px 2px rgba(0,0,0,0.1);
}

/* 隐藏子元素（如果存在） */
.tail-seg,
.tail-tip {
    display: none;
}

.legs {
    position: absolute;
    bottom: -12px;
    left: 10px;
    right: 10px;
    display: flex;
    justify-content: space-between;
}

.leg {
    width: 18px;
    height: 43px;
    background: #E4B872;
    border-radius: 10px;
}

/* 尾巴轻轻摇摆 */
@keyframes wag {
    0%, 100% {
        transform: rotate(10deg);
    }
    50% {
        transform: rotate(-12deg);
    }
}

@keyframes earSwing {
    0%, 100% {
        transform: rotate(0deg);
    }
    50% {
        transform: rotate(6deg);
    }
}

@keyframes sniff {
    0%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    50% {
        transform: translateX(-50%) translateY(2px);
    }
}

@keyframes idle {
    0%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    50% {
        transform: translateX(-50%) translateY(3px);
    }
}

/* Radial Cards with 3D flip effect */
.loading-screen .radial-card {
    position: absolute;
    width: clamp(140px, 15vw, 180px);
    height: clamp(160px, 17vw, 200px);
    transform: translate(-50%, -50%) scale(0);
    transform-style: preserve-3d;
    cursor: pointer;
    z-index: 5;
    overflow: visible;
    opacity: 0;
    visibility: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* Ensure cards scale with the hero-scale container */
    transform-origin: center center;
    /* Cards are positioned relative to the dog-cards-container */
    left: 50%;
    top: 50%;
}

/* Card entrance animations - dissolve effect: bottom-left → top-left → top-center → top-right → bottom-right */
/* Cards appear after text animation completes (around 8.5s) */
#card-hard {
    animation: cardDissolve 1s ease-out 9.0s forwards;
}

#card-dev {
    animation: cardDissolve 1s ease-out 9.4s forwards;
}

#card-ux {
    animation: cardDissolve 1s ease-out 9.8s forwards;
}

#card-ui {
    animation: cardDissolve 1s ease-out 10.2s forwards;
}

#card-ixd {
    animation: cardDissolve 1s ease-out 10.6s forwards;
}

@keyframes cardDissolve {
    from {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0;
        visibility: hidden;
        filter: blur(10px);
    }
    to {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
        visibility: visible;
        filter: blur(0);
    }
}

/* Card inner wrapper for flip */
.radial-card .card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transform-origin: center center;
    transition: transform 0.6s;
    border-radius: 16px;
    box-shadow: -5px -5px 8px #efeae0;
}

.radial-card:hover .card-inner,
.radial-card:focus-visible .card-inner {
    transform: rotateY(180deg);
}

/* Card front (icon + title) */
.card-front,
.card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    border-radius: 16px;
    overflow: hidden;
    
}

.card-front {
    background: #f4f0e7;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 0.8rem;
    padding: 15px;
    overflow: hidden;
    transform: translateZ(0);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* Hand-drawn style border */
    border-radius: 1.2rem;
}

.card-front::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 1.2rem;
    box-shadow: #33333333 1px 2px 0 1px;
    filter: url(#handDrawnNoise);
    animation: cardIdle 2s infinite ease-in-out;
    pointer-events: none;
    z-index: 1;
}

/* Blob background effect */
.card-front::before {
    content: '';
    position: absolute;
    z-index: 1;
    top: 50%;
    left: 50%;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    opacity: 0.6;
    filter: blur(40px);
    animation: blob-bounce 8s infinite ease;
    pointer-events: none;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

/* White overlay for content clarity */
.card-front::after {
    content: '';
    position: absolute;
    top: 5px;
    left: 5px;
    right: 5px;
    bottom: 5px;
    z-index: 2;
    backdrop-filter: blur(24px);
    border-radius: 10px;
    pointer-events: none;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

@keyframes blob-bounce {
    0% {
        transform: translate(-100%, -100%) translate3d(0, 0, 0);
    }
    25% {
        transform: translate(-100%, -100%) translate3d(100%, 0, 0);
    }
    50% {
        transform: translate(-100%, -100%) translate3d(100%, 100%, 0);
    }
    75% {
        transform: translate(-100%, -100%) translate3d(0, 100%, 0);
    }
    100% {
        transform: translate(-100%, -100%) translate3d(0, 0, 0);
    }
}

.card-front .card-icon {
    position: relative;
    z-index: 3;
}

.card-front .card-icon svg,
.card-front .card-icon img {
    width: clamp(36px, 4vw, 48px);
    height: clamp(36px, 4vw, 48px);
    color: #a6a6a6;
    transition: transform 0.3s ease, color 0.3s ease, filter 0.3s ease;
    object-fit: contain;
    animation: idle 2.2s ease-in-out infinite;
}

.radial-card:hover .card-front .card-icon svg,
.radial-card:hover .card-front .card-icon img {
    transform: scale(1.1);
}

/* Card hand-drawn animations */
@keyframes cardIdle {
    0% {
        filter: url(#handDrawnNoise);
    }
    25% {
        filter: url(#handDrawnNoise2);
    }
    50% {
        filter: url(#handDrawnNoise);
    }
    75% {
        filter: url(#handDrawnNoise2);
    }
    100% {
        filter: url(#handDrawnNoise);
    }
}

/* Card hand-drawn hover effects */
.radial-card:hover .card-front::after {
    filter: url(#handDrawnNoise2);
    box-shadow: #33333344 4px 4px 0 1px;
    animation: cardHover 1.5s infinite ease-in-out;
}

.radial-card:hover .card-back::after {
    filter: url(#handDrawnNoise2);
    box-shadow: #33333344 4px 4px 0 1px;
    animation: cardHoverBack 1.5s infinite ease-in-out;
}

@keyframes cardHover {
    0% {
        filter: url(#handDrawnNoise2);
    }
    50% {
        filter: url(#handDrawnNoise);
    }
    100% {
        filter: url(#handDrawnNoise2);
    }
}

@keyframes cardHoverBack {
    0% {
        filter: url(#handDrawnNoise2);
    }
    50% {
        filter: url(#handDrawnNoise);
    }
    100% {
        filter: url(#handDrawnNoise2);
    }
}

.card-front .card-title {
    position: relative;
    z-index: 3;
    font-weight: 700;
    font-size: clamp(0.8rem, 1.5vw, 0.95rem);
    line-height: 1.3;
    font-family: "Courier New", monospace;
    color: #333;
}

/* 卡片折角 */
.card-corner {
    position: absolute;
    bottom: 8px;
    right: 8px;
    width: 0;
    height: 0;
    border-left: 12px solid transparent;
    border-bottom: 12px solid #ff914d;
    border-bottom-left-radius: 4px;
    z-index: 4;
    animation: cornerFlip 2s ease-in-out infinite;
}

@keyframes cornerFlip {
    0% {
        transform: translate(-2px, -2px);
    }
    50% {
        transform: translate(1px, 1px);
    }
    100% {
        transform: translate(-2px, -2px);
    }
}

/* Card back (details with blob effect) */
.card-back {
    background: #f4f0e7;
    transform: rotateY(180deg);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    /* Hand-drawn style border */
    border-radius: 1.2rem;
}

.card-back::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 1.2rem;
    box-shadow: #33333333 3px 3px 0 1px;
    filter: url(#handDrawnNoise);
    animation: cardIdle 2s infinite ease-in-out;
    pointer-events: none;
    z-index: 1;
}

/* Blob background effect for back */
.card-back::before {
    content: '';
    position: absolute;
    z-index: 1;
    top: 50%;
    left: 50%;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background-color: #eaa74e;
    opacity: 0.4;
    filter: blur(40px);
    animation: blob-bounce 8s infinite ease;
    pointer-events: none;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

.card-back-content {
    position: absolute;
    width: 100%;
    height: 100%;
    background: #f4f0e7;
    backdrop-filter: blur(24px);
    border-radius: 16px;
    border: 1px solid #F3E2C4;
    color: #333;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.6rem;
    padding: 16px 20px;
    text-align: left;
    z-index: 2;
}

/* Card back question (h4) */
.card-question {
    font-weight: 700;
    font-size: clamp(1.1rem, 3vw, 1.4rem);
    line-height: 1.2;
    text-align: center;
    color: #333;
    margin: 0 0 0.5rem 0;
    font-family: "Courier New", monospace;
}

/* Card back subtitle (p) */
.card-subtitle {
    font-size: clamp(0.9rem, 2.5vw, 1.1rem);
    color: #666;
    margin: 0;
    text-align: center;
    line-height: 1.3;
    font-style: italic;
    font-family: "Courier New", monospace;
}

/* Card back skills (ul) */
.card-skills {
    font-size: clamp(0.8rem, 1.4vw, 0.85rem);
    color: #666;
    opacity: 0.95;
    text-align: left;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    list-style: none;
    font-family: "Courier New", monospace;
    width: 100%;
}

.card-skills li {
    position: relative;
    padding-left: 16px;
    margin-bottom: 4px;
}

.card-skills li:last-child {
    margin-bottom: 0;
}

.card-skills li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: #ff914d;
    font-weight: bold;
}

/* Hand-drawn Button */
.loading-screen .button-wrapper {
    position: absolute;
    top: calc(50% + 320px);
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    z-index: 15;
    opacity: 0;
    animation: buttonAppear 0.8s ease-out 10.9s forwards;
}

.loading-screen .hand-drawn-button {
    text-align: center;
    transition: 0.3s ease-in-out;
    cursor: pointer;
    background-color: transparent;
    filter: url(#handDrawnNoise);
    display: inline-flex;
    align-items: center;
    user-select: none;
    font-family: "Courier New", monospace;
    font-size: clamp(0.9rem, 2.2vw, 1.3rem);
    font-weight: bold;
    padding: clamp(0.7em, 1.8vw, 0.9em) clamp(1em, 2.5vw, 1.3em);
    border-width: 0px;
    border-radius: 2rem;
    box-shadow: #33333366 4px 4px 0 1px;
    animation: idle 1s infinite ease-in-out;
    position: relative;
}

.loading-screen .highlight {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    fill: rgba(255, 225, 0, 0.5);
    stroke: rgba(255, 225, 0, 0.5);
    stroke-width: 10;
    stroke-linecap: round;
    pointer-events: none;
    stroke-dasharray: 1000;
    stroke-dashoffset: 1000;
    transition: stroke-dashoffset 0.5s ease-in-out;
}

.loading-screen .button-cosm {
    fill: #33333366;
    transition: 0.3s ease-out;
    scale: 0.5;
    position: absolute;
    translate: calc(-100% + 24px) 1.5rem;
}

@keyframes buttonAppear {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

@keyframes idle {
    0% {
        filter: url(#handDrawnNoise);
    }
    50% {
        rotate: 2.5deg;
        filter: url(#handDrawnNoise2);
    }
    100% {
        filter: url(#handDrawnNoise);
    }
}

@keyframes hover {
    0% {
        rotate: 0deg;
        filter: url(#handDrawnNoise);
        translate: 0 0px;
    }
    25% {
        rotate: -1deg;
        filter: url(#handDrawnNoise2);
        translate: 0 -2px;
    }
    50% {
        rotate: 0deg;
        filter: url(#handDrawnNoise);
        translate: 0 2px;
    }
    75% {
        rotate: -1deg;
        filter: url(#handDrawnNoise2);
        translate: 0 -2px;
    }
    100% {
        rotate: 0deg;
        filter: url(#handDrawnNoise);
        translate: 0 0px;
    }
}

@keyframes active {
    0% {
        filter: url(#handDrawnNoiset);
        translate: 0 -1px;
    }
    25% {
        rotate: -3deg;
    }
    50% {
        filter: url(#handDrawnNoiset2);
        translate: 0 1px;
    }
    66% {
        rotate: 1.5deg;
    }
    100% {
        filter: url(#handDrawnNoiset);
        translate: 0 -1px;
    }
}

@keyframes highlight {
    0% {
        stroke-dashoffset: 0;
    }
    25% {
        stroke-dashoffset: 1000;
    }
    50% {
        stroke-dashoffset: 1000;
    }
    100% {
        stroke-dashoffset: 0;
    }
}

@keyframes col {
    0% {
        stroke: rgba(255, 225, 0, 0.5);
    }
    100% {
        stroke: #1c98eb66;
    }
}

/* Hover effects */
.loading-screen .hand-drawn-button:hover {
    font-weight: bold;
    border-width: 0px;
    border-radius: 2rem;
    rotate: -2.5deg;
    animation: hover 2.5s infinite ease-in-out;
}

.loading-screen .hand-drawn-button:hover .highlight {
    stroke-dashoffset: 0;
}

.loading-screen .hand-drawn-button:hover .button-cosm {
    rotate: -15deg;
    translate: calc(-100% + 22px) 1.9rem;
}

/* Active effects */
.loading-screen .hand-drawn-button:active {
    font-weight: bold;
    border-width: 0px;
    border-radius: 2rem;
    box-shadow: inset #333333f1 4px 4px 0 1px;
    rotate: -2.5deg;
    animation: active 1s infinite ease-in-out;
}

.loading-screen .hand-drawn-button:active .highlight {
    stroke-dashoffset: 1000;
    animation: highlight 5s infinite, col 0.5s forwards;
    stroke: #bc4e2666;
}

.loading-screen .hand-drawn-button:active .button-cosm {
    fill: #333333f1;
    rotate: -135deg;
    translate: calc(-100% + 55px) 1.6rem;
    animation: none;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: all 0.3s ease;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: 'Chelsea Market', cursive;
    font-weight: 400;
    font-size: 18px;
    color: #000;
    height: 100%;
}

.logo-img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

.nav-menu {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-link {
    text-decoration: none;
    color: #000;
    font-weight: 300;
    font-size: 1rem;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #666;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.bar {
    width: 25px;
    height: 2px;
    background: #000;
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0;
}

.hero-container {
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
    padding: 0 20px;
    text-align: left;
}

.hero-title {
    font-size: 80px;
    font-weight: 400;
    color: #000;
    margin-bottom: 20px;
    line-height: 1.3;
    opacity: 0;
    transform: translateY(30px);
    animation: slideUp 0.8s ease-out 0.2s forwards;
}

.hero-subtitle {
    font-size: 26px;
    color: #000;
    margin-bottom: 30px;
    line-height: 1.3;
    letter-spacing: 0.15em;
    opacity: 0;
    transform: translateY(30px);
    animation: slideUp 0.8s ease-out 0.4s forwards;
}

.hero-subtitle-light {
    font-weight: 100;
}

.hero-subtitle strong {
    font-weight: 250;
}

.hero-tags {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 100px;
    font-size: 16px;
    color: #828282;
    font-weight: 200;
    opacity: 0;
    transform: translateY(30px);
    animation: slideUp 0.8s ease-out 0.6s forwards;
}

.tag {
    color: #828282;
    font-weight: 200;
}

.tag:not(:last-child)::after {
    content: " · ";
    margin: 0 4px;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.btn {
    width: 30px;
    height: 50px;
    border-radius: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: transparent;
    border: none;
    outline: 2px solid rgb(134, 218, 82);
    box-shadow: 0px 0px 10px rgb(134, 218, 82);
    position: absolute;
    bottom: 120px;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    animation: slideUp 0.6s ease-out 0.6s forwards;
    cursor: pointer;
}

.scroll {
    width: 5px;
    height: 10px;
    border-radius: 10px;
    background-color: rgb(134, 218, 82);
    box-shadow: 0px 0px 10px rgb(134, 218, 82);
    animation: scroll_4013 1.5s linear infinite;
    transform: translateY(40%);
}

.btn:after {
    content: 'scroll';
    position: absolute;
    top: 140%;
    color: rgb(119, 191, 38);
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

@keyframes scroll_4013 {
    0% {
        transform: translateY(40%);
    }
    50% {
        transform: translateY(90%);
    }
}

/* Projects Section */
.projects {
    padding: 100px 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 60px;
    color: #000;
}

.project-card {
    margin-bottom: 80px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

.project-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
    padding: 40px;
}

.project-text {
    order: 1;
}

.project-title {
    font-size: 1.8rem;
    font-weight: 600;
    color: #000;
    margin-bottom: 20px;
}

.project-description {
    font-size: 1rem;
    color: #666;
    line-height: 1.7;
    font-weight: 400;
}

.project-image {
    order: 2;
    text-align: center;
}

.project-img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

/* About Section */
.about {
    padding: 100px 0;
    background: #f8fafc;
}

.about-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-text p {
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 20px;
    line-height: 1.7;
    font-weight: 400;
}

.about-image {
    text-align: center;
}

.profile-img {
    max-width: 100%;
    height: auto;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Contact Section */
.contact {
    padding: 100px 0;
    background: white;
}

.contact-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.contact-text h3 {
    font-size: 2rem;
    font-weight: 600;
    color: #000;
    margin-bottom: 20px;
}

.contact-text p {
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 40px;
    font-weight: 400;
}

.contact-links {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.contact-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    background: #f8fafc;
    color: #666;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.contact-link:hover {
    background: #000;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

/* Footer */
.footer {
    background: #000;
    color: white;
    text-align: center;
    padding: 40px 0;
}

.footer p {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 30px;
    }

    .nav-container {
        padding: 0 30px;
    }

    .hero-container {
        padding: 0 30px;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: white;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 20px 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-toggle.active .bar:nth-child(2) {
        opacity: 0;
    }

    .nav-toggle.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .nav-toggle.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .project-content {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 30px;
    }

    .project-text {
        order: 2;
    }

    .project-image {
        order: 1;
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }

    .contact-links {
        flex-direction: column;
        align-items: center;
    }

    .section-title {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 20px;
    }

    .nav-container {
        padding: 0 20px;
    }

    .hero-container {
        padding: 0 20px;
    }

    .hero-title {
        font-size: 2rem;
    }

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

    .project-card {
        margin-bottom: 40px;
    }

    .project-content {
        padding: 20px;
    }
}

/* Smooth scrolling for anchor links */
html {
    scroll-behavior: smooth;
}

/* Focus states for accessibility */
.nav-link:focus,
.contact-link:focus {
    outline: 2px solid #000;
    outline-offset: 2px;
}

/* Loading animation */
.loading {
    opacity: 0;
    animation: fadeInUp 0.6s ease-out forwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Loading screen responsive adjustments */
@media (max-width: 1024px) {
    .landing-nav-container {
        padding: 0 15px;
        height: 65px;
    }
    
    .landing-logo-img {
        width: 45px;
        height: 45px;
    }
    
    .landing-logo-text {
        font-size: 16px;
    }
    
    .loading-screen .radial-card {
        width: clamp(130px, 14vw, 170px);
        height: clamp(150px, 16vw, 190px);
    }
    
    .loading-screen .card-front .card-icon img,
    .loading-screen .card-front .card-icon svg {
        width: clamp(28px, 3.5vw, 42px);
        height: clamp(28px, 3.5vw, 42px);
    }
    
    .loading-screen .card-front .card-title {
        font-size: clamp(0.7rem, 1.3vw, 0.9rem);
    }
    
    .loading-screen .card-question {
        font-size: clamp(0.75rem, 1.4vw, 0.85rem);
    }
    
    .loading-screen .card-skills {
        font-size: clamp(0.6rem, 1.1vw, 0.7rem);
    }
    
    .loading-screen .card-back-content {
        padding: 14px 16px;
        gap: 0.5rem;
    }
    
    .loading-screen .intro {
        max-width: 80vw;
        padding: 0 20px;
    }
}

@media (max-width: 768px) {
    .landing-nav-container {
        padding: 0 12px;
        height: 60px;
    }
    
    .landing-logo-img {
        width: 40px;
        height: 40px;
    }
    
    .landing-logo-text {
        font-size: 15px;
    }
    
    .loading-screen .radial-card {
        width: clamp(110px, 12vw, 150px);
        height: clamp(130px, 14vw, 170px);
    }
    
    .loading-screen .card-front .card-icon img,
    .loading-screen .card-front .card-icon svg {
        width: clamp(24px, 3vw, 36px);
        height: clamp(24px, 3vw, 36px);
    }
    
    .loading-screen .card-front .card-title {
        font-size: clamp(0.65rem, 1.2vw, 0.85rem);
    }
    
    .loading-screen .card-question {
        font-size: clamp(0.7rem, 1.3vw, 0.8rem);
    }
    
    .loading-screen .card-skills {
        font-size: clamp(0.55rem, 1vw, 0.65rem);
    }
    
    .loading-screen .card-back-content {
        padding: 12px 14px;
        gap: 0.4rem;
    }
    
    .loading-screen .intro {
        max-width: 85vw;
        padding: 0 15px;
    }
    
    .loading-screen .intro h2 {
        font-size: clamp(1.5rem, 3.5vw, 2rem);
    }
    
    .loading-screen .intro p {
        font-size: clamp(0.85rem, 2.2vw, 0.95rem);
    }
}

@media (max-width: 480px) {
    .landing-nav-container {
        padding: 0 10px;
        height: 55px;
    }
    
    .landing-logo-img {
        width: 35px;
        height: 35px;
    }
    
    .landing-logo-text {
        font-size: 14px;
    }
    
    .loading-screen .dog {
        width: clamp(70px, 20vw, 120px);
        height: clamp(90px, 25vw, 150px);
    }
    
    .loading-screen .radial-card {
        width: clamp(90px, 10vw, 130px);
        height: clamp(110px, 12vw, 150px);
    }
    
    .loading-screen .card-front .card-icon img,
    .loading-screen .card-front .card-icon svg {
        width: clamp(20px, 2.5vw, 30px);
        height: clamp(20px, 2.5vw, 30px);
    }
    
    .loading-screen .card-front .card-title {
        font-size: clamp(0.6rem, 1.1vw, 0.8rem);
    }
    
    .loading-screen .card-question {
        font-size: clamp(0.65rem, 1.2vw, 0.75rem);
    }
    
    .loading-screen .card-skills {
        font-size: clamp(0.5rem, 0.9vw, 0.6rem);
    }
    
    .loading-screen .card-skills li {
        padding-left: 12px;
        margin-bottom: 3px;
    }
    
    .loading-screen .card-back-content {
        padding: 10px 12px;
        gap: 0.3rem;
    }
    
    .loading-screen .intro h2 {
        font-size: clamp(1.3rem, 4vw, 1.8rem);
        line-height: 1.1;
    }
    
    .loading-screen .intro p {
        font-size: clamp(0.8rem, 2.3vw, 0.9rem);
    }
    
    .loading-screen .intro {
        max-width: 90vw;
        padding: 0 12px;
    }
    
    .loading-screen .button-wrapper {
        top: calc(50% + 260px);
    }
    
    .loading-screen .hand-drawn-button {
        font-size: clamp(0.9rem, 2.2vw, 1.3rem);
        padding: clamp(0.7em, 1.8vw, 0.9em) clamp(1em, 2.5vw, 1.3em);
    }
}

@media (max-width: 360px) {
    .landing-nav-container {
        padding: 0 8px;
        height: 50px;
    }
    
    .landing-logo-img {
        width: 30px;
        height: 30px;
    }
    
    .landing-logo-text {
        font-size: 13px;
    }
    
    .loading-screen .dog {
        width: clamp(60px, 18vw, 100px);
        height: clamp(80px, 22vw, 130px);
    }
    
    .loading-screen .radial-card {
        width: clamp(80px, 9vw, 120px);
        height: clamp(100px, 11vw, 140px);
    }
    
    .loading-screen .card-front .card-icon img,
    .loading-screen .card-front .card-icon svg {
        width: clamp(18px, 2.2vw, 26px);
        height: clamp(18px, 2.2vw, 26px);
    }
    
    .loading-screen .card-front .card-title {
        font-size: clamp(0.55rem, 1vw, 0.75rem);
    }
    
    .loading-screen .card-question {
        font-size: clamp(0.6rem, 1.1vw, 0.7rem);
    }
    
    .loading-screen .card-skills {
        font-size: clamp(0.45rem, 0.8vw, 0.55rem);
    }
    
    .loading-screen .card-skills li {
        padding-left: 10px;
        margin-bottom: 2px;
    }
    
    .loading-screen .card-back-content {
        padding: 8px 10px;
        gap: 0.25rem;
    }
    
    .loading-screen .intro h2 {
        font-size: clamp(1.2rem, 4.5vw, 1.6rem);
        line-height: 1.1;
    }
    
    .loading-screen .intro p {
        font-size: clamp(0.75rem, 2.5vw, 0.85rem);
    }
    
    .loading-screen .intro {
        max-width: 95vw;
        padding: 0 10px;
    }
    
    .loading-screen .button-wrapper {
        top: calc(50% + 240px);
    }
    
    .loading-screen .hand-drawn-button {
        font-size: clamp(0.8rem, 2vw, 1.1rem);
        padding: clamp(0.6em, 1.6vw, 0.8em) clamp(0.8em, 2.2vw, 1.1em);
    }
}
