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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans JP", sans-serif;
    background-color: #0a0a0a;
    color: #e0e0e0;
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* Neural-ish background canvas */
#particle-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

/* Top tabs */
.top-tabs {
    position: fixed;
    top: 16px;
    left: 16px;
    z-index: 10;
    display: flex;
    gap: 10px;
}

.top-tabs .tab {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    background: rgba(26, 26, 26, 0.85);
    color: #e0e0e0;
    text-decoration: none;
    border-radius: 8px;
    border: 1px solid #2a2a2a;
    font-size: 0.95rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(6px);
}

.top-tabs .tab:hover {
    border-color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 255, 255, 0.08);
}

.top-tabs .tab.active {
    background: rgba(42, 42, 42, 0.92);
    border-color: #ffffff;
    color: #ffffff;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 24px;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 80px;
    padding-bottom: 40px;
    border-bottom: 1px solid #2a2a2a;
}

.profile-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    margin-bottom: 32px;
}

.profile-icon {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #ffffff;
    animation: fadeInUp 0.8s ease-out;
    box-shadow: 0 8px 32px rgba(255, 255, 255, 0.1);
}

.profile-text {
    text-align: center;
}

.name {
    font-size: 3.5rem;
    font-weight: 200;
    letter-spacing: 0.05em;
    color: #ffffff;
    margin-bottom: 12px;
    animation: fadeInUp 0.8s ease-out 0.1s both;
}

.tagline {
    font-size: 1.2rem;
    color: #888888;
    font-weight: 300;
    letter-spacing: 0.1em;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

.social-links {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-inline: auto;
    animation: fadeInUp 0.8s ease-out 0.3s both;
}

.social-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: #1a1a1a;
    color: #e0e0e0;
    text-decoration: none;
    border-radius: 2px;
    border: 1px solid #2a2a2a;
    font-size: 0.95rem;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.social-link:hover {
    border-color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(255, 255, 255, 0.1);
}

.social-link svg {
    flex-shrink: 0;
}

/* Sections */
.section {
    margin-bottom: 80px;
    animation: fadeInUp 0.6s ease-out both;
}

.section-title {
    font-size: 1.8rem;
    font-weight: 300;
    color: #ffffff;
    margin-bottom: 32px;
    padding-bottom: 12px;
    border-bottom: 1px solid #1a1a1a;
    letter-spacing: 0.05em;
}

/* Profile */
.profile-info {
    background: linear-gradient(135deg, #1a1a1a 0%, #0f0f0f 100%);
    padding: 32px;
    border-radius: 2px;
    border-left: 2px solid #ffffff;
}

.profile-info p {
    margin-bottom: 12px;
    font-size: 1.05rem;
}

.profile-info p:last-child {
    margin-bottom: 0;
}

.label {
    color: #888888;
    font-weight: 400;
    min-width: 80px;
    display: inline-block;
}

/* Interests */
.interest-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
}

.interest-item {
    background: #1a1a1a;
    padding: 28px;
    border-radius: 2px;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid #2a2a2a;
}

.interest-item:hover {
    transform: translateY(-4px);
    border-color: #ffffff;
    box-shadow: 0 8px 24px rgba(255, 255, 255, 0.1);
}

.interest-title {
    font-size: 1.2rem;
    font-weight: 400;
    color: #ffffff;
    margin-bottom: 12px;
}

.interest-detail {
    color: #888888;
    font-size: 0.95rem;
    line-height: 1.8;
}

/* Affiliation */
.affiliation-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.affiliation-item {
    background: #1a1a1a;
    padding: 20px 28px;
    border-radius: 2px;
    border-left: 2px solid #666666;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.affiliation-item:hover {
    border-left-color: #ffffff;
}

.affiliation-item.with-link {
    cursor: pointer;
}

.affiliation-sub {
    font-size: 1rem;
    color: #cccccc;
}

.affiliation-link {
    display: block;
    margin-top: 12px;
    color: #888888;
    font-size: 0.9rem;
    text-decoration: none;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: all 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.affiliation-item.with-link:hover .affiliation-link {
    opacity: 1;
    max-height: 50px;
}

.affiliation-link:hover {
    color: #ffffff;
}

/* Skills */
.skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

.skill-tag {
    background: #1a1a1a;
    color: #ffffff;
    padding: 12px 24px;
    border-radius: 2px;
    border: 1px solid #2a2a2a;
    font-size: 1rem;
    font-weight: 400;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.skill-tag:hover {
    border-color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(255, 255, 255, 0.1);
}

/* Research */
.research-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.research-card {
    background: #1a1a1a;
    padding: 28px;
    border-radius: 2px;
    border: 1px solid #2a2a2a;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.research-card:hover {
    transform: translateY(-4px);
    border-color: #ffffff;
    box-shadow: 0 8px 24px rgba(255, 255, 255, 0.1);
}

.research-card-title {
    font-size: 1.3rem;
    font-weight: 400;
    color: #ffffff;
    margin-bottom: 12px;
}

.research-card-desc {
    color: #888888;
    font-size: 0.95rem;
    line-height: 1.8;
}

/* Timeline */
.timeline {
    position: relative;
    padding-left: 0;
}

.year-group {
    margin-bottom: 48px;
}

.year-label {
    font-size: 2rem;
    font-weight: 300;
    color: #ffffff;
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 2px solid #2a2a2a;
    letter-spacing: 0.05em;
}

.year-items {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.timeline-item {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 24px;
    padding: 20px;
    background: #1a1a1a;
    border-radius: 2px;
    border-left: 2px solid #444444;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    transform-style: preserve-3d;
}

.timeline-item:hover {
    border-left-color: #ffffff;
    transform: translateX(4px);
}

.timeline-date {
    font-size: 0.9rem;
    color: #888888;
    font-weight: 400;
    white-space: nowrap;
}

.timeline-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.achievement-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
}

.achievement-title {
    color: #e0e0e0;
    font-size: 1.05rem;
    line-height: 1.6;
    flex: 1;
}

.achievement-award {
    color: #ffffff;
    font-size: 1.15rem;
    font-weight: 500;
    padding: 8px 16px;
    background: #2a2a2a;
    border-radius: 2px;
    white-space: nowrap;
    flex-shrink: 0;
}

.achievement-detail {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    margin-top: 0;
    transition: all 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.achievement-detail p {
    color: #888888;
    font-size: 0.95rem;
    line-height: 1.6;
    padding-top: 12px;
    border-top: 1px solid #2a2a2a;
    margin-bottom: 8px;
}

.achievement-detail p:first-child {
    border-top: 1px solid #2a2a2a;
    padding-top: 12px;
}

.achievement-detail p:last-of-type {
    margin-bottom: 12px;
}

.achievement-link {
    color: #888888;
    font-size: 0.9rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: color 0.4s ease;
}

.achievement-link:hover {
    color: #ffffff;
}

.timeline-item:hover .achievement-detail {
    max-height: 300px;
    opacity: 1;
    margin-top: 8px;
}

/* Filter System */
.filter-container {
    margin-bottom: 32px;
}

.filter-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.filter-btn {
    background: #1a1a1a;
    color: #888888;
    border: 1px solid #2a2a2a;
    padding: 10px 20px;
    border-radius: 2px;
    cursor: pointer;
    font-size: 0.95rem;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: inherit;
}

.filter-btn:hover {
    color: #ffffff;
    border-color: #444444;
}

.filter-btn.active {
    background: #2a2a2a;
    color: #ffffff;
    border-color: #ffffff;
}

/* GitHub Section */
.github-section {
    margin-bottom: 80px;
}

.github-activity {
    min-height: 200px;
}

.github-activity img {
    width: 100%;
    height: auto;
    display: block;
}

.loading {
    text-align: center;
    color: #888888;
    padding: 40px;
}

.error {
    color: #ff6b6b;
}

/* Works / Vlog Articles */
.article-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

/* Make Vlog/Works cards look like Achievements: one-column, full-width */
.vlog-page .article-grid,
.works-page .article-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

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

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

/* Vlog toolbar (search / tag filter) */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.vlog-toolbar {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 28px;
}

.vlog-search {
    width: 100%;
    max-width: 420px;
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 2px;
    color: #ffffff;
    font-family: inherit;
    font-size: 0.95rem;
    padding: 12px 16px;
    transition: border-color 0.4s ease;
}

.vlog-search::placeholder {
    color: #666666;
}

.vlog-search:focus {
    outline: none;
    border-color: #ffffff;
}

.vlog-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag-chip {
    background: #1a1a1a;
    color: #888888;
    border: 1px solid #2a2a2a;
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 0.85rem;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.tag-chip:hover {
    color: #ffffff;
    border-color: #444444;
}

.tag-chip.active {
    background: #2a2a2a;
    color: #ffffff;
    border-color: #ffffff;
}

.vlog-count {
    color: #888888;
    font-size: 0.85rem;
    margin: 0;
}

/* Vlog pagination */
.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-top: 32px;
}

.pagination[hidden] {
    display: none;
}

.page-btn {
    background: #1a1a1a;
    color: #b8b8b8;
    border: 1px solid #2a2a2a;
    border-radius: 2px;
    padding: 8px 14px;
    font-size: 0.9rem;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.page-btn:hover:not(:disabled) {
    color: #ffffff;
    border-color: #444444;
}

.page-btn.active {
    background: #2a2a2a;
    color: #ffffff;
    border-color: #ffffff;
}

.page-btn:disabled {
    opacity: 0.4;
    cursor: default;
}

.article-card {
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 2px;
    padding: 24px;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
}

.article-card:hover {
    border-color: #ffffff;
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(255, 255, 255, 0.1);
}

/* Vlog/Works: horizontal rectangular card (image on the left) */
.article-card.vlog-card,
.article-card.works-card {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 24px;
    align-items: stretch;
    min-height: 180px;
    padding: 20px;
    border-left: 2px solid #444444;
}

/* Works: 画像は記事詳細ページ右側へ移動済み → 1カラム構成 */
.article-card.works-card {
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    grid-template-columns: 1fr;
    min-height: 140px;
    align-items: start;
    align-content: start;
}

/* Achievements-like hover（Profile の .timeline-item と同じ動き） */
.article-card.vlog-card:hover,
.article-card.works-card:hover {
    transform: translateX(4px);
    border-color: #2a2a2a;
    border-left-color: #ffffff;
    box-shadow: none;
}

.article-card.works-card .article-title {
    letter-spacing: normal;
    font-weight: 500;
}

.article-card.works-card .article-hover-content {
    background: rgba(255, 255, 255, 0.05);
    border-left-color: #ffffff;
}

.article-card.vlog-card .article-image-wrap {
    width: 80px;
    min-height: 120px;
    height: auto;
    aspect-ratio: auto;
    margin-bottom: 0;
    background: rgba(0, 0, 0, 0.2);
}

.article-card.vlog-card .article-title,
.article-card.vlog-card .article-date,
.article-card.vlog-card .article-views,
.article-card.vlog-card .article-hover-content,
.article-card.vlog-card .article-content {
    grid-column: 2;
}

@media (max-width: 600px) {
    .article-card.vlog-card,
    .article-card.works-card {
        grid-template-columns: 1fr;
        gap: 14px;
        min-height: 0;
    }

    .article-card.vlog-card .article-image-wrap {
        width: 100%;
        height: auto;
        aspect-ratio: 1 / 1;
        margin-bottom: 16px;
    }

    .article-card.vlog-card .article-title,
    .article-card.vlog-card .article-date,
    .article-card.vlog-card .article-views,
    .article-card.vlog-card .article-hover-content,
    .article-card.vlog-card .article-content {
        grid-column: auto;
    }
}

.article-image-wrap {
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    position: relative;
    margin-bottom: 16px;
    border-radius: 2px;
    background: #0a0a0a;
    display: flex;
    align-items: center;
    justify-content: center;
}


.article-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.article-hover-content {
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    color: #cccccc;
    font-size: 0.85rem;
    line-height: 1.5;
    margin-bottom: 0;
    padding: 0 14px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    border-left: 2px solid #ffffff;
    transition: all 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.article-card:hover .article-hover-content {
    opacity: 1;
    max-height: 500px;
    margin-bottom: 14px;
    padding: 14px;
}

.article-hover-content .inline-link {
    color: #888888;
    text-decoration: none;
    transition: color 0.4s ease;
    word-break: break-all;
}

.article-hover-content .inline-link:hover {
    color: #ffffff;
}

.article-title {
    color: #ffffff;
    font-size: 1.2rem;
    font-weight: 500;
    margin-bottom: 10px;
}

.article-date {
    color: #888888;
    font-size: 0.9rem;
    margin-bottom: 12px;
}

.article-views {
    color: #666666;
    font-size: 0.75rem;
    margin-top: -6px;
    margin-bottom: 10px;
}

.article-content {
    color: #888888;
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 14px;
}

.article-link-wrap {
    display: flex;
    align-items: center;
}

.article-link {
    color: #888888;
    font-size: 0.95rem;
    text-decoration: none;
    transition: color 0.4s ease;
}

.article-link:hover {
    color: #ffffff;
}

/* BGM Consent Modal */
.bgm-consent {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.65);
    padding: 18px;
}

.bgm-consent-card {
    width: 100%;
    max-width: 520px;
    background: rgba(26, 26, 26, 0.96);
    border: 1px solid #2a2a2a;
    border-radius: 12px;
    padding: 20px 18px;
    box-shadow: 0 16px 60px rgba(0, 0, 0, 0.35);
    text-align: center;
    color: #e0e0e0;
}

.bgm-consent-title {
    font-size: 1.35rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 10px;
}

.bgm-consent-text {
    color: #bdbdbd;
    font-size: 0.98rem;
    line-height: 1.6;
    margin-bottom: 14px;
}

.bgm-consent-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 6px;
    flex-wrap: wrap;
}

.bgm-consent-ok,
.bgm-consent-no {
    padding: 10px 18px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid #ffffff;
}

.bgm-consent-ok {
    background: #2a2a2a;
    color: #ffffff;
}

.bgm-consent-ok:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(255, 255, 255, 0.06);
}

.bgm-consent-no {
    background: transparent;
    color: #cfcfcf;
    border-color: #666666;
}

.bgm-consent-no:hover {
    transform: translateY(-2px);
    border-color: #ffffff;
    color: #ffffff;
}

/* BGM Controls */
.bgm-controls {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 30;
    display: block;
    min-width: 260px;
    background: rgba(26, 26, 26, 0.86);
    border: 1px solid #2a2a2a;
    border-radius: 12px;
    padding: 12px 14px;
    backdrop-filter: blur(6px);
    box-shadow: 0 12px 50px rgba(0, 0, 0, 0.35);
}

.bgm-controls-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.bgm-volume-label {
    color: #bdbdbd;
    font-size: 0.95rem;
    font-weight: 400;
    white-space: nowrap;
}

.bgm-volume {
    --bgm-level: 40%;
    flex: 1;
    -webkit-appearance: none;
    appearance: none;
    height: 8px;
    border-radius: 999px;
    /* Brighter = louder, filled up to the current volume */
    background: linear-gradient(90deg,
        #3aa7cc 0%,
        #78dcff var(--bgm-level),
        rgba(120, 220, 255, 0.14) var(--bgm-level),
        rgba(120, 220, 255, 0.14) 100%);
    border: 1px solid rgba(120, 220, 255, 0.35);
    outline: none;
}

.bgm-volume-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* Low end: small, dim speaker shape */
.bgm-volume-icon--low {
    color: rgba(170, 185, 195, 0.5);
}

/* High end: larger speaker shape with waves, in the accent color */
.bgm-volume-icon--high {
    color: #78dcff;
    filter: drop-shadow(0 0 5px rgba(120, 220, 255, 0.45));
}

.bgm-volume::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #78dcff;
    border: 2px solid rgba(255, 255, 255, 0.9);
    box-shadow: 0 0 0 4px rgba(120, 220, 255, 0.12);
    cursor: pointer;
}

.bgm-volume::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #78dcff;
    border: 2px solid rgba(255, 255, 255, 0.9);
    box-shadow: 0 0 0 4px rgba(120, 220, 255, 0.12);
    cursor: pointer;
}

.bgm-volume:focus {
    box-shadow: 0 0 0 3px rgba(120, 220, 255, 0.18);
}

.bgm-toggle {
    padding: 8px 12px;
    border-radius: 10px;
    cursor: pointer;
    background: rgba(120, 220, 255, 0.10);
    color: #eaffff;
    border: 1px solid rgba(120, 220, 255, 0.65);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.95rem;
    white-space: nowrap;
}

.bgm-toggle:hover {
    transform: translateY(-2px);
    background: rgba(120, 220, 255, 0.16);
    box-shadow: 0 10px 30px rgba(120, 220, 255, 0.10);
}

@media (max-width: 480px) {
    .bgm-controls {
        right: 12px;
        bottom: 12px;
        min-width: unset;
        width: calc(100vw - 24px);
    }

    .bgm-controls-row {
        gap: 8px;
    }
}

/* Contact */
.contact-form {
    max-width: 640px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.contact-row {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.contact-row label {
    color: #888888;
    font-size: 0.9rem;
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 2px;
    color: #e0e0e0;
    padding: 10px 12px;
    font-size: 0.95rem;
    font-family: inherit;
    transition: border-color 0.4s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: #ffffff;
}

.contact-form textarea {
    resize: vertical;
    min-height: 100px;
}

/* ハニーポット: 画面から消すがinput自体は残す（display:noneだとbotに気づかれる） */
.contact-hp {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.contact-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

/* Turnstile: sitekey 未設定のときは空なので余白を出さない */
.turnstile-container:not(:empty) {
    margin: 8px 0;
}

.contact-form button {
    background: transparent;
    border: 1px solid #444444;
    border-radius: 2px;
    color: #888888;
    padding: 10px 28px;
    font-size: 0.95rem;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.contact-form button:hover:not(:disabled) {
    border-color: #ffffff;
    color: #ffffff;
}

.contact-form button:disabled {
    opacity: 0.5;
    cursor: default;
}

.contact-status {
    color: #888888;
    font-size: 0.9rem;
}

/* Footer */
.footer {
    margin-top: 100px;
    padding-top: 40px;
    border-top: 1px solid #2a2a2a;
    text-align: center;
}

.footer p {
    color: #666666;
    font-size: 0.9rem;
    font-weight: 300;
}

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

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 40px 20px;
    }

    .profile-icon {
        width: 120px;
        height: 120px;
    }

    .name {
        font-size: 2.5rem;
    }

    .social-links {
        flex-direction: column;
        width: 100%;
        max-width: 300px;
    }

    .social-link {
        width: 100%;
        justify-content: center;
    }

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

    .interest-grid,
    .research-grid {
        grid-template-columns: 1fr;
    }

    .timeline-item {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .timeline-date {
        font-size: 0.85rem;
    }

    .top-tabs {
        top: 10px;
        left: 10px;
        gap: 8px;
        flex-wrap: wrap;
        max-width: calc(100vw - 20px);
    }
}

@media (max-width: 480px) {
    .name {
        font-size: 2rem;
    }

    .profile-icon {
        width: 100px;
        height: 100px;
    }

    .profile-info {
        padding: 24px;
    }

    .interest-item,
    .research-card {
        padding: 20px;
    }

    .article-card {
        padding: 20px;
    }
}

/* ===== Article detail page (generated from content/*.md) ===== */
/* 記事本文を星背景から分離する薄いパネル（カード配色 #1a1a1a / #2a2a2a と統一） */
.article-detail {
    background: #141414;
    border: 1px solid #2a2a2a;
    border-radius: 2px;
    padding: 32px;
}

.article-detail .article-back {
    display: inline-block;
    color: #a6a6a6;
    font-size: 0.9rem;
    text-decoration: none;
    margin-bottom: 18px;
    transition: color 0.4s ease;
}

.article-detail .article-back:hover {
    color: #ffffff;
}

.article-detail .article-date {
    margin-top: -20px;
    margin-bottom: 24px;
    color: #a6a6a6;
}

.article-detail .article-views {
    margin-top: -14px;
    margin-bottom: 24px;
    color: #888888;
    font-size: 0.85rem;
}

/* タイトル（左）＋ アイコン画像（右）のヘッダー行 */
.article-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
}

.article-head-text {
    flex: 1;
    min-width: 0;
}

.article-detail-image {
    flex-shrink: 0;
    width: 140px;
    height: 140px;
    object-fit: contain;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid #2a2a2a;
    border-radius: 2px;
    padding: 8px;
}

@media (max-width: 600px) {
    .article-detail {
        padding: 20px;
    }

    .article-head {
        flex-direction: column;
        gap: 16px;
    }

    .article-detail-image {
        width: 110px;
        height: 110px;
        order: -1;
    }
}

/* 目次 */
.article-toc {
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 2px;
    padding: 18px 22px;
    margin: 24px 0;
}

.article-toc-title {
    color: #ffffff;
    font-size: 1rem;
    margin: 0 0 10px;
}

.article-toc-list {
    margin: 0;
    padding-left: 1.2em;
    color: #b8b8b8;
}

.toc-item a {
    color: #b8b8b8;
    text-decoration: none;
    transition: color 0.4s ease;
}

.toc-item a:hover {
    color: #ffffff;
}

.toc-level-3 {
    margin-left: 1em;
}

/* 前後の記事ナビ */
.article-nav {
    display: flex;
    gap: 16px;
    margin: 32px 0 0;
}

.article-nav-link {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 2px;
    padding: 14px 18px;
    text-decoration: none;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
    min-width: 0;
}

.article-nav-link.next {
    text-align: right;
}

.article-nav-link.is-empty {
    visibility: hidden;
}

.article-nav-link:hover {
    border-color: #ffffff;
    transform: translateY(-2px);
}

.article-nav-label {
    color: #888888;
    font-size: 0.8rem;
}

.article-nav-title {
    color: #ffffff;
    font-size: 0.95rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 関連記事 */
.article-related {
    margin-top: 40px;
    padding-top: 24px;
    border-top: 1px solid #2a2a2a;
}

.article-related-title {
    color: #ffffff;
    font-size: 1rem;
    margin: 0 0 14px;
}

.related-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.related-card {
    display: flex;
    flex-direction: column;
    gap: 4px;
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 2px;
    padding: 12px 14px;
    text-decoration: none;
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.related-card:hover {
    border-color: #ffffff;
    transform: translateY(-2px);
}

.related-title {
    color: #e0e0e0;
    font-size: 0.9rem;
}

.related-date {
    color: #888888;
    font-size: 0.78rem;
}

.article-related-more {
    margin: 16px 0 0;
}

.article-related-more a {
    color: #b8b8b8;
    text-decoration: none;
    font-size: 0.9rem;
}

.article-related-more a:hover {
    color: #ffffff;
}

/* ページ上部へ戻る */
.article-top-link {
    margin: 32px 0 0;
    text-align: center;
}

.article-top-link a {
    color: #a6a6a6;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.4s ease;
}

.article-top-link a:hover {
    color: #ffffff;
}

@media (max-width: 600px) {
    .article-nav {
        flex-direction: column;
    }

    .article-nav-link.is-empty {
        display: none;
    }

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

.article-body {
    color: #e0e0e0;
    font-size: 1.02rem;
    line-height: 1.9;
}

.article-body p {
    margin-bottom: 1.1em;
}

.article-body h1,
.article-body h2,
.article-body h3,
.article-body h4,
.article-body h5,
.article-body h6 {
    color: #ffffff;
    font-weight: 500;
    line-height: 1.4;
    margin: 1.8em 0 0.7em;
}

.article-body h1 { font-size: 1.6rem; }
.article-body h2 { font-size: 1.4rem; }
.article-body h3 { font-size: 1.2rem; }
.article-body h4 { font-size: 1.05rem; }
.article-body h5,
.article-body h6 { font-size: 1rem; }

.article-body a {
    color: #b8b8b8;
    text-decoration: none;
    word-break: break-all;
    transition: color 0.4s ease;
}

.article-body a:hover {
    color: #ffffff;
}

.article-body strong {
    color: #ffffff;
    font-weight: 600;
}

.article-body ul,
.article-body ol {
    margin: 0 0 1.1em 1.5em;
}

.article-body li {
    margin-bottom: 0.4em;
}

.article-body code {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid #2a2a2a;
    border-radius: 4px;
    padding: 0.1em 0.4em;
    font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
    font-size: 0.92em;
}

.article-body pre {
    background: #111111;
    border: 1px solid #2a2a2a;
    border-radius: 6px;
    padding: 16px;
    overflow-x: auto;
    margin-bottom: 1.1em;
}

.article-body pre code {
    background: none;
    border: none;
    padding: 0;
    font-size: 0.9rem;
    line-height: 1.6;
}

.article-body blockquote {
    border-left: 2px solid #ffffff;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 0 4px 4px 0;
    padding: 12px 16px;
    margin-bottom: 1.1em;
    color: #d6d6d6;
}

.article-body img {
    max-width: 100%;
    border-radius: 4px;
    margin: 0.5em 0;
}

.article-body hr {
    border: none;
    border-top: 1px solid #2a2a2a;
    margin: 2em 0;
}

/* 3Dチルト（マウス追従）はカーソルに素早く追従させ、他の遷移は緩やかなままにする */
.timeline-item,
.interest-item,
.research-card,
.article-card {
    transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1), transform 0.15s ease-out;
}

/* アニメーションを抑制する設定（OS/ブラウザ設定を尊重） */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }
}
