* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #3b82f6;
    --primary-dark: #2563eb;
    --secondary-color: #06b6d4;
    --accent-color: #8b5cf6;
    --bg-color: #0f172a;
    --card-bg: #1e293b;
    --card-bg-hover: #263449;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --border-color: #334155;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --gradient-1: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
    --gradient-2: linear-gradient(135deg, #06b6d4 0%, #3b82f6 100%);
    --gradient-3: linear-gradient(135deg, #8b5cf6 0%, #ec4899 100%);
    --hardware: #f59e0b;
    --embedded: #3b82f6;
    --diy: #10b981;
    --creative: #ec4899;
}

body {
    font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.7;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Header Section */
.header {
    padding: 100px 0 80px;
    text-align: center;
    background: 
        radial-gradient(ellipse at top, rgba(59, 130, 246, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at bottom, rgba(139, 92, 246, 0.1) 0%, transparent 50%);
    border-bottom: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: 
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 40px,
            rgba(59, 130, 246, 0.03) 40px,
            rgba(59, 130, 246, 0.03) 41px
        );
    animation: scan 20s linear infinite;
    pointer-events: none;
}

@keyframes scan {
    0% { transform: translateY(0); }
    100% { transform: translateY(40px); }
}

.profile-section {
    max-width: 700px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.avatar {
    width: 160px;
    height: 160px;
    margin: 0 auto 28px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid var(--primary-color);
    box-shadow: 
        0 0 0 4px rgba(59, 130, 246, 0.2),
        0 0 40px rgba(59, 130, 246, 0.3);
    transition: all 0.4s ease;
}

.avatar:hover {
    transform: scale(1.05) rotate(2deg);
    box-shadow: 
        0 0 0 6px rgba(59, 130, 246, 0.3),
        0 0 60px rgba(59, 130, 246, 0.5);
}

.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.name {
    font-size: 2.75rem;
    font-weight: 700;
    margin-bottom: 12px;
    background: linear-gradient(135deg, #fff 0%, #60a5fa 50%, #a78bfa 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
}

.title {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
    font-weight: 500;
}

.subtitle {
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 28px;
    font-style: italic;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 16px;
}

.social-link {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: var(--card-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}

.social-link::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-1);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.social-link:hover {
    transform: translateY(-4px);
    border-color: transparent;
    box-shadow: 0 12px 24px rgba(59, 130, 246, 0.25);
}

.social-link:hover::before {
    opacity: 1;
}

.social-link svg {
    width: 22px;
    height: 22px;
    position: relative;
    z-index: 1;
    transition: color 0.3s ease;
}

.social-link:hover svg {
    color: white;
}

/* Main Content */
.main-content {
    padding: 80px 0;
}

.section {
    margin-bottom: 100px;
}

.section-title {
    font-size: 1.875rem;
    font-weight: 600;
    margin-bottom: 40px;
    display: flex;
    align-items: center;
    gap: 16px;
    letter-spacing: -0.01em;
}

.section-title::before {
    content: '';
    width: 5px;
    height: 32px;
    background: var(--gradient-1);
    border-radius: 3px;
}

/* About Section */
.about-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.about-text {
    font-size: 1.125rem;
    color: var(--text-secondary);
    line-height: 1.9;
    max-width: 850px;
}

.about-text strong {
    color: var(--text-primary);
    font-weight: 600;
}

/* Skills Section */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.skill-card {
    background: var(--card-bg);
    border-radius: 20px;
    padding: 32px;
    border: 1px solid var(--border-color);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.skill-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.skill-card.hardware::before { background: var(--hardware); }
.skill-card.embedded::before { background: var(--embedded); }
.skill-card.diy::before { background: var(--diy); }
.skill-card.creative::before { background: var(--creative); }

.skill-card:hover {
    transform: translateY(-6px);
    background: var(--card-bg-hover);
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.4);
}

.skill-card:hover::before {
    transform: scaleX(1);
}

.skill-icon {
    font-size: 2.75rem;
    margin-bottom: 20px;
    display: block;
}

.skill-card h3 {
    font-size: 1.375rem;
    margin-bottom: 12px;
    color: var(--text-primary);
    font-weight: 600;
}

.skill-card > p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 20px;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.skill-tags .tag {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid var(--border-color);
}

/* Approach Section */
.approach-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
}

.approach-card {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 28px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    position: relative;
}

.approach-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-4px);
}

.approach-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    opacity: 0.3;
    line-height: 1;
    margin-bottom: 16px;
}

.approach-card h3 {
    font-size: 1.125rem;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.approach-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
}

/* Projects Section */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 28px;
}

.project-card {
    background: var(--card-bg);
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    transition: all 0.4s ease;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary-color);
    box-shadow: 0 28px 56px rgba(0, 0, 0, 0.4);
}

.project-image {
    width: 100%;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.project-image::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 0%, rgba(15, 23, 42, 0.6) 100%);
}

.project-placeholder {
    font-size: 4.5rem;
    position: relative;
    z-index: 1;
}

.project-content {
    padding: 28px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.project-card h3 {
    font-size: 1.25rem;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.project-card > .project-content > p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 16px;
    flex: 1;
}

.project-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 16px;
}

.meta-item {
    font-size: 0.8rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.03);
    padding: 6px 12px;
    border-radius: 8px;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag {
    background: rgba(59, 130, 246, 0.12);
    color: var(--primary-color);
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Hobbies Section */
.hobbies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 20px;
}

.hobby-card {
    background: var(--card-bg);
    border-radius: 20px;
    padding: 28px 20px;
    text-align: center;
    border: 1px solid var(--border-color);
    transition: all 0.4s ease;
    cursor: default;
}

.hobby-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary-color);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.hobby-icon {
    font-size: 2.5rem;
    display: block;
    margin-bottom: 16px;
}

.hobby-card h3 {
    font-size: 1.125rem;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.hobby-card p {
    color: var(--text-secondary);
    font-size: 0.85rem;
    line-height: 1.5;
}

/* Photography Section */
.section-desc {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: 32px;
    margin-top: -24px;
}

.photo-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 250px;
    gap: 16px;
}

.photo-item {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.4s ease;
}

.photo-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.photo-item:hover {
    transform: scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.photo-item:hover img {
    transform: scale(1.1);
}

.photo-item.large {
    grid-column: span 2;
    grid-row: span 2;
}

.photo-item.wide {
    grid-column: span 2;
}

.photo-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 24px;
    background: linear-gradient(180deg, transparent 0%, rgba(15, 23, 42, 0.95) 100%);
    transform: translateY(100%);
    transition: transform 0.4s ease;
}

.photo-item:hover .photo-overlay {
    transform: translateY(0);
}

.photo-title {
    display: block;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.photo-desc {
    display: block;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Thinking Section */
.thinking-content {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.quote-card {
    background: var(--card-bg);
    border-radius: 20px;
    padding: 40px;
    border: 1px solid var(--border-color);
    position: relative;
}

.quote-card::before {
    content: '"';
    position: absolute;
    top: 20px;
    left: 24px;
    font-size: 4rem;
    color: var(--primary-color);
    opacity: 0.2;
    font-family: Georgia, serif;
    line-height: 1;
}

.quote-card blockquote {
    font-size: 1.25rem;
    color: var(--text-primary);
    font-style: italic;
    line-height: 1.8;
    position: relative;
    z-index: 1;
}

.thinking-topics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
}

.topic-item {
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--card-bg);
    padding: 20px 24px;
    border-radius: 14px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.topic-item:hover {
    border-color: var(--primary-color);
    transform: translateX(8px);
}

.topic-icon {
    font-size: 1.75rem;
}

.topic-text {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* Timeline Section */
.timeline {
    position: relative;
    padding-left: 40px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--primary-color) 0%, var(--accent-color) 100%);
}

.timeline-item {
    position: relative;
    margin-bottom: 48px;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-marker {
    position: absolute;
    left: -40px;
    top: 4px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--bg-color);
    border: 3px solid var(--primary-color);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.2);
}

.timeline-content {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 28px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.timeline-content:hover {
    border-color: var(--primary-color);
}

.timeline-content h3 {
    font-size: 1.25rem;
    margin-bottom: 6px;
    color: var(--text-primary);
}

.company {
    color: var(--primary-color);
    font-weight: 500;
    margin-bottom: 4px;
    font-size: 0.95rem;
}

.date {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 14px;
}

.description {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
}

/* Contact Section */
.contact-content {
    background: var(--card-bg);
    border-radius: 24px;
    padding: 56px;
    text-align: center;
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}

.contact-content::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.1) 0%, transparent 70%);
    animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

.contact-content > * {
    position: relative;
    z-index: 1;
}

.contact-content > p:first-child {
    color: var(--text-secondary);
    font-size: 1.25rem;
    margin-bottom: 16px;
}

.contact-note {
    color: var(--primary-color);
    font-size: 1rem;
    font-style: italic;
    margin-bottom: 32px;
}

.contact-btn {
    display: inline-block;
    background: var(--gradient-1);
    color: white;
    padding: 16px 40px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 8px 24px rgba(59, 130, 246, 0.35);
    border: none;
    cursor: pointer;
}

.contact-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(59, 130, 246, 0.5);
}

/* Footer */
.footer {
    padding: 48px 0;
    text-align: center;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.section {
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

.section:nth-child(1) { animation-delay: 0.1s; }
.section:nth-child(2) { animation-delay: 0.2s; }
.section:nth-child(3) { animation-delay: 0.3s; }
.section:nth-child(4) { animation-delay: 0.4s; }
.section:nth-child(5) { animation-delay: 0.5s; }
.section:nth-child(6) { animation-delay: 0.6s; }
.section:nth-child(7) { animation-delay: 0.7s; }
.section:nth-child(8) { animation-delay: 0.8s; }
.section:nth-child(9) { animation-delay: 0.9s; }

/* Responsive Design */
@media (max-width: 768px) {
    .header {
        padding: 70px 0 50px;
    }
    
    .name {
        font-size: 2.25rem;
    }
    
    .title {
        font-size: 1.1rem;
    }
    
    .subtitle {
        font-size: 0.9rem;
    }
    
    .avatar {
        width: 130px;
        height: 130px;
    }
    
    .main-content {
        padding: 50px 0;
    }
    
    .section {
        margin-bottom: 70px;
    }
    
    .section-title {
        font-size: 1.625rem;
    }
    
    .skills-grid,
    .approach-grid {
        grid-template-columns: 1fr;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .thinking-topics {
        grid-template-columns: 1fr;
    }
    
    .hobbies-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
    
    .hobby-card {
        padding: 20px 16px;
    }
    
    .photo-gallery {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 180px;
        gap: 12px;
    }
    
    .photo-item.large {
        grid-column: span 2;
        grid-row: span 2;
    }
    
    .photo-item.wide {
        grid-column: span 2;
    }
    
    .contact-content {
        padding: 36px 24px;
    }
    
    .quote-card {
        padding: 28px;
    }
    
    .quote-card blockquote {
        font-size: 1.1rem;
    }
    
    .timeline {
        padding-left: 28px;
    }
    
    .timeline-marker {
        left: -28px;
        width: 16px;
        height: 16px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }
    
    .name {
        font-size: 1.875rem;
    }
    
    .section-title {
        font-size: 1.375rem;
    }
    
    .skill-card,
    .approach-card {
        padding: 24px;
    }
    
    .project-content {
        padding: 20px;
    }
    
    .topic-item {
        padding: 16px 20px;
    }
    
    .timeline-content {
        padding: 20px;
    }
    
    .hobbies-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .hobby-icon {
        font-size: 2rem;
    }
    
    .photo-gallery {
        grid-template-columns: 1fr;
        grid-auto-rows: 200px;
    }
    
    .photo-item.large,
    .photo-item.wide {
        grid-column: span 1;
        grid-row: span 1;
    }
}
