:root {
    /* Console Style Color Palette */
    --bg-main: #0B0B0E;
    --bg-card: #15151A;
    --bg-nav: rgba(11, 11, 14, 0.85);
    
    --text-main: #FAFAFA;
    --text-muted: #A0A0B0;
    
    --accent-blue: #0070F3; /* Modern bright blue */
    --accent-hover: #3291FF;
    --border-color: #26262F;
    --border-hover: #4B4B5C;
    
    --award-gold: #FFD700;
    
    --transition-fast: all 0.15s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --transition-smooth: all 0.3s ease;
}

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

body {
    font-family: 'Inter', 'Noto Sans JP', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4 {
    font-weight: 800;
    letter-spacing: -0.02em;
}

.title {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 20px;
    letter-spacing: -0.03em;
}

.section-title {
    font-size: 2.2rem;
    color: var(--text-main);
    margin-bottom: 30px;
}

/* Navigation */
.console-nav {
    position: fixed;
    top: 0;
    width: 100%;
    height: 70px;
    background: var(--bg-nav);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    z-index: 100;
}

.nav-container {
    max-width: 1200px;
    height: 100%;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 40px;
}

.logo {
    font-size: 1.5rem;
    color: var(--text-main);
    text-transform: uppercase;
    letter-spacing: 2px;
}
.logo span {
    color: var(--text-muted);
    font-weight: 400;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 30px;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: var(--transition-fast);
}

.nav-links a:hover {
    color: var(--text-main);
}

/* Layout */
.section {
    padding: 100px 40px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Hero Section */
#hero {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding-top: 150px;
    padding-bottom: 0;
}

#about {
    padding-top: 20px;
}

.hero-content {
    max-width: 800px;
}

.badge-outline {
    display: inline-block;
    padding: 6px 16px;
    border: 1px solid var(--border-hover);
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 20px;
}

.hero-content p {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 40px;
    max-width: 800px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: var(--transition-fast);
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: #10b981;
    color: #ffffff !important;
    border: none;
    box-shadow: none !important;
    font-weight: 600;
}

.btn-primary:hover {
    background: #059669;
    box-shadow: none !important;
    transform: translateY(-1px);
    color: #ffffff !important;
}

.btn-secondary {
    background: #dc2626;
    color: #ffffff !important;
    border: none;
    box-shadow: none !important;
    font-weight: 600;
}

.btn-secondary:hover {
    background: #b91c1c;
    box-shadow: none !important;
    transform: translateY(-1px);
    color: #ffffff !important;
}

/* 詳細ボタン (ブルーカラー) */
.btn-primary[data-ja*="詳細"],
.btn-info-detail {
    background: #2563eb;
    color: #ffffff !important;
    border: none;
    box-shadow: none !important;
    font-weight: 600;
}

.btn-primary[data-ja*="詳細"]:hover,
.btn-info-detail:hover {
    background: #1d4ed8;
    box-shadow: none !important;
    transform: translateY(-1px);
    color: #ffffff !important;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.85rem;
}

/* X (Twitter) 用ボタン */
.btn-x {
    background: #0f1419 !important;
    color: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, 0.25) !important;
    box-shadow: none !important;
    font-weight: 600;
}

.btn-x:hover {
    background: #272c30 !important;
    border-color: rgba(255, 255, 255, 0.5) !important;
    transform: translateY(-1px);
}

.hero-buttons {
    display: flex;
    gap: 15px;
}

/* ナビゲーション用ボタン (作品を見る / 資料を見る の色復元) */
.hero-buttons .btn-primary {
    background: var(--text-main) !important;
    color: var(--bg-main) !important;
    border: 1px solid var(--text-main) !important;
    box-shadow: none !important;
    font-weight: 600;
}

.hero-buttons .btn-primary:hover {
    background: var(--text-muted) !important;
    border-color: var(--text-muted) !important;
    transform: translateY(-2px);
}

.hero-buttons .btn-secondary {
    background: transparent !important;
    color: var(--text-main) !important;
    border: 1px solid var(--border-color) !important;
    box-shadow: none !important;
    font-weight: 600;
}

.hero-buttons .btn-secondary:hover {
    border-color: var(--text-main) !important;
    background: rgba(255, 255, 255, 0.05) !important;
    transform: translateY(-2px);
}

/* Cards (Works, About) */
.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.console-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 40px;
    transition: var(--transition-fast);
}

.console-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

/* Profile / Skills */
.profile-pic-container {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    margin-bottom: 20px;
    background: var(--bg-main);
    border: 2px solid var(--border-color);
    overflow: hidden;
}

.profile-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #26262F, #15151A);
}

.skill-group {
    margin-bottom: 20px;
}

.skill-group label {
    display: block;
    font-weight: 500;
    font-size: 0.9rem;
    margin-bottom: 8px;
    color: var(--text-muted);
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: var(--bg-main);
    border-radius: 3px;
    overflow: hidden;
}

.progress {
    height: 100%;
    background: var(--text-main);
    border-radius: 3px;
}

/* Works Section */
.works-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

@media (max-width: 1024px) {
    .works-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .works-grid {
        grid-template-columns: 1fr;
    }
}

/* Steam Store Style Modal */
.steam-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(10, 14, 22, 0.88);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.steam-modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.steam-modal-window {
    background: linear-gradient(135deg, #1b2838 0%, #171a21 100%);
    border: 1px solid rgba(103, 193, 245, 0.3);
    border-radius: 12px;
    max-width: 820px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.95), 0 0 50px rgba(103, 193, 245, 0.2);
    color: #c6d4df;
    transform: scale(0.9) translateY(20px);
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.steam-modal-overlay.active .steam-modal-window {
    transform: scale(1) translateY(0);
}

.steam-close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    font-size: 1.6rem;
    line-height: 1;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.2s;
}

.steam-close-btn:hover {
    background: #67c1f5;
    color: #171a21;
    transform: scale(1.1);
}

/* Steam Header Banner */
.steam-header {
    position: relative;
    width: 100%;
    height: 280px;
    overflow: hidden;
    background: #0b0b0e;
    display: flex;
    align-items: center;
    justify-content: center;
}

.steam-banner-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #0b0b0e;
}

.steam-header-title {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 30px 30px 15px;
    background: linear-gradient(to top, rgba(23, 26, 33, 1) 0%, rgba(23, 26, 33, 0.7) 60%, transparent 100%);
}

.steam-header-title h2 {
    font-size: 1.9rem;
    color: #ffffff;
    text-shadow: 0 2px 10px rgba(0,0,0,0.9);
}

/* Steam Body Layout */
.steam-body {
    display: grid;
    grid-template-columns: 1fr 240px;
    gap: 25px;
    padding: 25px 30px 35px;
}

@media (max-width: 768px) {
    .steam-body {
        grid-template-columns: 1fr;
    }
}

.steam-actions {
    background: rgba(0, 0, 0, 0.35);
    padding: 15px 20px;
    border-radius: 6px;
    margin-bottom: 25px;
    display: flex;
    gap: 12px;
    align-items: center;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

/* Steam Sidebar Meta */
.steam-side-box {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 20px;
}

.steam-award-box {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.steam-award-badge-ui {
    background: rgba(255, 215, 0, 0.12);
    border: 1px solid rgba(255, 215, 0, 0.5);
    color: #ffd700;
    padding: 8px 12px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.85rem;
    display: inline-block;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.15);
    margin-top: 4px;
}

.steam-meta-item {
    font-size: 0.85rem;
}

.steam-meta-label {
    color: #56707f;
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.steam-meta-val {
    color: #67c1f5;
    font-weight: 600;
    line-height: 1.4;
}

.steam-section-title {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #67c1f5;
    border-bottom: 1px solid rgba(103, 193, 245, 0.25);
    padding-bottom: 8px;
    margin-bottom: 15px;
}

.steam-desc-content {
    font-size: 0.92rem;
    line-height: 1.7;
    color: #acb2b8;
}

/* Work Card Grid Style */
.work-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    position: relative;
    cursor: pointer;
    user-select: none;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), border-color 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
}

.work-card:hover {
    border-color: #67c1f5;
    transform: translateY(-4px);
    box-shadow: 0 12px 35px rgba(103, 193, 245, 0.2);
}

.work-card:hover {
    border-color: var(--accent-blue);
    transform: translateY(-4px);
    box-shadow: 0 12px 35px rgba(0, 112, 243, 0.18);
}

/* 浮遊展開（クリックしたカードが手前に浮かび上がり、下へ"にゅんっ"と伸びる） */
.work-card.expanded {
    z-index: 100;
    border-color: var(--accent-blue);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), 0 0 30px rgba(0, 112, 243, 0.3);
    transform: translateY(-6px) scale(1.02);
}

.work-img-container {
    width: 100%;
    height: 170px;
    background: var(--bg-main);
    position: relative;
    overflow: hidden;
    border-radius: 13px;
}

.work-img-container::after {
    content: "▼";
    position: absolute;
    bottom: 6px;
    right: 6px;
    background: rgba(11, 11, 14, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: var(--text-main);
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 0.65rem;
    font-weight: 700;
    border: 1px solid var(--border-color);
    z-index: 3;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.work-card:hover .work-img-container::after {
    background: var(--accent-blue);
    border-color: var(--accent-hover);
    transform: scale(1.1);
}

.work-card.expanded .work-img-container::after {
    content: "▲";
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
}

.work-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.work-card:hover .work-img {
    transform: scale(1.05);
}

/* 右上のJamバッジを非表示 */
.work-badge {
    display: none !important;
}

.award-badge {
    position: absolute;
    bottom: 6px;
    left: 6px;
    background: rgba(11, 11, 14, 0.9);
    backdrop-filter: blur(4px);
    color: var(--award-gold);
    padding: 4px 10px;
    border-radius: 4px;
    font-weight: 800;
    font-size: 0.75rem;
    z-index: 2;
    border: 1px solid rgba(255, 215, 0, 0.5);
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.15);
}

/* 作品カード内は一覧時はアイコンのみを表示 */
.work-info {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

/* Documents */
.docs-intro {
    color: var(--text-muted);
    margin-bottom: 30px;
}

.doc-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 15px;
}

.doc-item {
    display: flex;
    align-items: center;
    padding: 20px 25px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

.doc-item:hover {
    border-color: var(--border-hover);
    background: #1A1A21;
}

.doc-icon {
    font-size: 1.8rem;
    margin-right: 20px;
}

.doc-meta {
    flex-grow: 1;
}

.doc-meta h4 {
    font-size: 1.1rem;
    margin-bottom: 4px;
}

.doc-meta p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.doc-action {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-main);
    padding: 6px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    transition: var(--transition-fast);
}

.doc-item:hover .doc-action {
    background: var(--text-main);
    color: var(--bg-main);
}

/* Footer & Contact */
#contact {
    text-align: center;
    padding: 80px 40px;
    border-top: 1px solid var(--border-color);
}

#contact h2 {
    margin-bottom: 15px;
}

#contact p {
    color: var(--text-muted);
    margin-bottom: 30px;
}

.social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    transition: var(--transition-bounce);
    margin-top: 20px;
}

/* Mobile Responsive Optimizations */
@media (max-width: 768px) {
    .steam-modal-overlay {
        padding: 12px;
    }
    
    .steam-modal-window {
        max-height: 94vh;
        border-radius: 10px;
    }
    
    .steam-header {
        height: 180px;
    }
    
    .steam-header-title {
        padding: 15px 20px 10px;
    }
    
    .steam-header-title h2 {
        font-size: 1.35rem;
    }
    
    .steam-body {
        padding: 18px 20px 25px;
        gap: 20px;
    }
    
    .steam-actions {
        flex-wrap: wrap;
        gap: 10px;
        padding: 12px;
    }
    
    .steam-actions .btn {
        flex: 1 1 calc(50% - 10px);
        text-align: center;
        padding: 10px 14px;
        font-size: 0.88rem;
    }
    
    .steam-side-box {
        padding: 15px;
    }
}

@media (max-width: 480px) {
    .works-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .work-img-container {
        height: 140px;
    }

    .steam-actions .btn {
        flex: 1 1 100%;
    }
}

.social-icon:hover {
    transform: translateY(-5px);
    background: var(--text-main);
    color: var(--bg-main);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.1);
}

footer {
    text-align: center;
    padding: 30px;
    color: var(--text-muted);
    font-size: 0.85rem;
    border-top: 1px solid var(--border-color);
}

/* Animation */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 768px) {
    .grid-2 { grid-template-columns: 1fr; }
    .title { font-size: 2rem; }
    .nav-links { display: none; }
    .hero-buttons { flex-direction: column; }
    .doc-item { flex-direction: column; text-align: left; align-items: flex-start; }
    .doc-icon { margin-bottom: 10px; margin-right: 0; }
    .doc-action { margin-top: 15px; }
    
    /* スマホ用に余白を削り、PCと同じ文字の改行リズムを担保する調整 */
    .section { padding: 50px 10px; }
    .nav-container { padding: 0 15px; }
    .work-info { padding: 15px 10px; }
    .work-desc { font-size: 0.9rem; line-height: 1.6; }
    
    /* スマホの狭い画面でPC用の改行が暴発して形が崩れるのを防ぐため、スマホ表示時のみ改行を無効化 */
    .work-desc br { display: none; }
    
    #contact { padding: 50px 10px; }
}
