/* ギャラリーページ固有のスタイル */
:root {
    --background: #f5f7fa;
    --card-bg: rgba(255, 255, 255, 0.7);
    --text: #1d1d1f;
    --text-secondary: #86868b;
    --accent: #0066cc;
}

.header {
    background: rgba(44, 44, 46, 0.55);
    color: white;
    padding: 1.5rem 0;
    position: fixed;
    width: 100%;
    z-index: 1000;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background-color: var(--bg-light);
    color: var(--text);
    -webkit-font-smoothing: antialiased;
}

.header-spacer {
    height: calc(1.5rem * 3);
    width: 100%;
}

.main-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.year-section {
    margin-bottom: 4rem;
    position: relative;
}

.year-title {
    font-size: 1.6rem;
    font-weight: 600;
    margin-bottom: 2.5rem;
    letter-spacing: -0.02em;
    color: var(--text);
    position: relative;
    background: linear-gradient(90deg, rgba(128, 128, 128, 1) 0%, rgba(128, 128, 128, 0.1) 100%);
    padding: 0.5rem 2rem;
    border-radius: 4px;
    color: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    padding: 0 1rem;
}

.project-card {
    background: var(--card-bg);
    border-radius: 1rem;
    overflow: hidden;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.project-image-container {
    position: relative;
    width: 100%;
    padding-top: 75%;
    overflow: hidden;
}

.project-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
}

.project-card:hover .project-image {
    transform: scale(1.05);
}

.project-info {
    padding: 1.5rem;
}

.project-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    letter-spacing: -0.01em;
}

.project-author {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.project-awards {
    font-size: 0.875rem;
    color: var(--accent);
    font-weight: 500;
}

/* アニメーション */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.project-card {
    animation: fadeIn 0.6s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

/* No Image Placeholder スタイル */
.no-image-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #f5f5f5;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.no-image-icon {
    width: 48px;
    height: 48px;
    opacity: 0.5;
    color: #666;
    margin-bottom: 0.5rem;
}

.no-image-text {
    color: #666;
    font-size: 0.875rem;
    font-weight: 500;
}

/* ホバーエフェクト */
.project-card:hover .no-image-placeholder {
    background-color: #ebebeb;
}

/* レスポンシブ対応 */
@media (max-width: 1200px) {
    .projects-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

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

@media (max-width: 768px) {
    .main-content {
        padding: 1rem;
    }

    .projects-grid {
        gap: 1rem;
    }

    .year-title {
        font-size: 1.75rem;
        padding: 0.75rem 1.5rem;
        margin-bottom: 2rem;
    }
}

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

/* ダークモード対応 */
@media (prefers-color-scheme: dark) {
    :root {
        --background: #1d1d1f;
        --card-bg: rgba(40, 40, 40, 0.7);
        --text: #f5f5f7;
        --text-secondary: #a1a1a6;
        --accent: #2997ff;
    }

    .year-title {
        background: linear-gradient(90deg, var(--accent) 0%, rgba(41, 151, 255, 0.1) 100%);
    }

    .no-image-placeholder {
        background-color: #2c2c2e;
    }

    .no-image-icon,
    .no-image-text {
        color: #999;
    }

    .project-card:hover .no-image-placeholder {
        background-color: #3c3c3e;
    }
}