body {
    font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
    background: #f9f9f9;
    /* 明るめの背景に変更（デザイン画白ベースのため） */
    color: #333;
    margin: 0;
    line-height: 1.6;
}

/* ==========================================================================
   Common Layout
   ========================================================================== */
.event-detail,
.event-archive {
    max-width: 1500px;
    margin: 0 auto;
    padding: 24px;
    background: #fff;
}

/* ==========================================================================
   Event Archive (List Page)
   ========================================================================== */
.archive-header {
    text-align: center;
    margin-bottom: 40px;
}

.archive-title-img {
    width: 50%;
    height: auto;
}

.archive-title {
    font-size: 2rem;
    margin-bottom: 10px;
    border-bottom: 2px solid #ddd;
    display: inline-block;
    padding-bottom: 5px;
}

.archive-subtitle {
    font-size: 1rem;
    margin-top: 10px;
}

.event-notice {
    text-align: center;
    margin-top: 20px;
    font-size: 0.9em;
}

.sort-controls {
    margin-bottom: 20px;
    text-align: right;
}

.sort-btn {
    background: #f0f0f0;
    border: 1px solid #ccc;
    padding: 8px 16px;
    margin-right: 10px;
    cursor: pointer;
    font-size: 0.95rem;
    border-radius: 4px;
    color: #555;
    transition: background 0.3s, color 0.3s;
}

.sort-btn:hover {
    background: #e0e0e0;
}

.sort-btn.active {
    background: #666;
    color: #fff;
    border-color: #666;
}

.event-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.event-card {
    background: #fff;
    border: 2px solid #888;
    /* グレーの枠線（デザイン画準拠） */
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    transition: transform 0.2s, box-shadow 0.2s;
}

.event-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.event-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

/* Thumb & Month Badge */
.event-card-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #eee;
    border-bottom: 1px solid #ccc;
    display: flex;
    /* 画像がない場合のセンタリング用 */
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.event-card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.event-card-thumb img.placeholder-logo {
    width: 70%;
    height: auto;
    object-fit: contain;
}

/* Month Badge (Top Left) */
.event-badge.month {
    position: absolute;
    top: 12px;
    left: -6px;
    background: #666;
    /* Match design gray */
    color: #fff;
    padding: 2px 10px 2px 8px;
    font-weight: bold;
    /* Regular weight in design? Looks bold. */
    font-size: 1rem;
    clip-path: polygon(0 0, 100% 0, 85% 50%, 100% 100%, 0 100%);
    box-shadow: 2px 2px 3px rgba(0, 0, 0, 0.3);
    z-index: 1;
}

/* Planned Badge (Top Right) */
.event-badge.planned {
    position: absolute;
    top: 12px;
    right: 12px;
    background: #e65100;
    color: #fff;
    padding: 2px 10px;
    font-weight: bold;
    font-size: 0.85rem;
    border-radius: 4px;
    box-shadow: 2px 2px 3px rgba(0, 0, 0, 0.3);
    z-index: 1;
}

/* MVP Badge */
.event-badge.mvp {
    /* Flex item in title-row now */
    background: #666;
    color: #fff;
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: bold;
    white-space: nowrap;
    margin-left: 10px;
    height: fit-content;
}

/* Card Body */
.event-card-body {
    padding: 15px;
}

.event-date {
    display: block;
    font-size: 1rem;
    font-weight: bold;
    color: #333;
    margin-bottom: 8px;
    border-bottom: 1px solid #ccc;
    /* Separator line */
    padding-bottom: 5px;
}

.event-title-row {
    display: flex;
    justify-content: space-around;
    align-items: flex-start;
    margin-bottom: 15px;
}

.event-title {
    font-size: 1rem;
    line-height: 1.4;
    margin: 0;
    font-weight: bold;
    /* 2 lines max */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.event-more-btn {
    display: block;
    text-align: center;
    border: 1px solid #666;
    padding: 6px;
    font-size: 0.9rem;
    color: #333;
    font-weight: bold;
    background: #fff;
    text-decoration: none;
    border-radius: 4px;
    /* Slightly rounded button */
    width: 60%;
    /* Not full width in design? Looks roughly 60-70% centered */
    margin: 0 auto;
}

.event-card:hover .event-more-btn {
    background: #f0f0f0;
}


/* ==========================================================================
   Event Detail Page
   ========================================================================== */
.event-detail-page,
.event-archive-page {
    max-width: 1000px;
    margin: 0 auto;
    padding: 24px;
    background: #fff;
}

.content-title {
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 20px;
}

.event-header {
    border: 2px solid #888;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 40px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: center;
}

.event-header-image {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #eee;
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}

.event-header-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.event-header-text h1.event-title {
    font-size: 1.8rem;
    margin: 0 0 15px 0;
    border-bottom: none;
    /* リセット */
}

.event-header-text .event-date-detail {
    font-size: 1rem;
    color: #555;
    display: block;
    margin-bottom: 15px;
}

.event-header-text .event-lead {
    font-size: 1rem;
}


/* Section Titles */
/* ===== Cool & Modern H2 Heading ===== */
/* =========================
   Event Page H2 Heading
   ========================= */
h2.section-title {
    background: linear-gradient(to right, #0ba0f0, #89c8eb);
    /* 背景色グラデーション */
    color: #fff;
    /* 文字色 */
    overflow: hidden;
    padding: 10px 40px 10px 20px;
    /* 余白 */
    position: relative;
    margin: 40px 0;
    /* マージン調整 */
    border-radius: 50px 0 0 50px;
    /* 左側を丸く */
    min-width: 300px;
    /* 最低限の幅確保 */
}

h2.section-title:before {
    background-color: #fff;
    /* 切り替わる色1 */
    content: '';
    display: block;
    opacity: 0.3;
    /* 不透明度 */
    transform: rotate(-50deg);
    position: absolute;
    bottom: -10px;
    right: -330px;
    width: 500px;
    height: 500px;
}

/* 下に走るアクセントライン */
h2.section-title::after {
    background-color: #fff;
    /* 切り替わる色2 */
    content: '';
    display: block;
    opacity: 0.3;
    /* 不透明度 */
    transform: rotate(-70deg);
    position: absolute;
    bottom: -100px;
    right: -500px;
    width: 500px;
    height: 500px;
}


/* Event Summary (Definition List) */
.event-summary-list {
    background: #f4f4f4;
    padding: 20px;
    border-radius: 8px;
}

.event-summary-list div {
    display: grid;
    grid-template-columns: 200px 1fr;
    margin-bottom: 10px;
    border-bottom: 1px dotted #ccc;
    padding-bottom: 10px;
}

.event-summary-list div:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.event-summary-list dt {
    font-weight: bold;
    color: #555;
    background: #e0e0e0;
    text-align: center;
    padding: 2px 5px;
    border-radius: 4px;
    margin-right: 15px;
    white-space: nowrap;
}

.event-summary-list dd {
    margin: 0;
    text-align: left;
}


/* Participants / Member List */
.member-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 0;
    list-style: none;
}

.member-list li {
    background: #fff;
    border: 1px solid #aaa;
    border-radius: 20px;
    padding: 5px 15px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
}

.member-icon {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
}



/* MVP Section */
.event-mvp {
    background: #fff;
    margin-bottom: 40px;
}

.mvp-banner {
    display: inline-block;
    padding: 0.5em 1.5em;
    /* パディングを増やしてふっくらさせる */
    margin-bottom: 32px;
    color: #fff;
    /* 白文字で可愛らしく */
    background: #3fbcff;
    /* 指定のベースカラー */
    border-radius: 50px;
    /* 角丸（カプセル型） */
    font-weight: bold;
    letter-spacing: 0.05em;
    line-height: 1.3;
    vertical-align: middle;
    box-shadow: 0 4px 10px rgba(63, 188, 255, 0.4);
    /* ふんわりした影 */
    border: 2px solid #fff;
    /* 内側の白枠でポップさをプラス */
    outline: 2px solid #3fbcff;
    /* 外側の枠で強調 */
    outline-offset: 2px;
}

.mvp-banner:before {
    content: '★';
    /* ●から★に変更 */
    color: #fff;
    margin-right: 8px;
    font-size: 1.2em;
    /* アイコンを少し大きく */
    vertical-align: -2px;
}

.mvp-label {
    font-size: 1.2rem;
    font-weight: 900;
}

.mvp-highlight {
    color: #ffeb3b;
    /* 明るい黄色 */
}

.mvp-card-container {
    display: flex;
    gap: 20px;
}

.mvp-card {
    width: 100%;
    box-sizing: border-box;
}

.mvp-card {
    flex: 1;
    max-width: calc(50% - 10px);
    border: 2px solid #aaa;
    border-radius: 10px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    position: relative;
}

.mvp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.mvp-name {
    font-size: 1.2rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 10px;
}

.mvp-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid #ddd;
}

.mvp-icon-sm {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
    vertical-align: middle;
    margin-right: 5px;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.comment-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    vertical-align: middle;
    margin-right: 10px;
    border: 1px solid #ddd;
}


.mvp-badge {
    background: #666;
    color: white;
    padding: 2px 12px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: bold;
}

.mvp-reason-title {
    font-size: 0.8rem;
    font-weight: bold;
    margin-bottom: 5px;
}

.mvp-reason p {
    text-align: left;
    margin: 0;
}


/* Gallery */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 10px;
    list-style: none;
    padding: 0;
}

.gallery-grid li {
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: 8px;
    border: 1px solid #ddd;
}

.gallery-grid img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.gallery-grid img:hover {
    transform: scale(1.05);
}


/* Comments */
.event-comments {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.comment-card {
    border: 2px solid #ccc;
    border-radius: 12px;
    padding: 15px;
    background: #f9f9f9;
}

.comment-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    border-bottom: 1px solid #ddd;
    padding-bottom: 5px;
    font-weight: bold;
}

.comment-content p {
    text-align: left;
    margin: 0;
}

/* Special Thanks */
.comment-card.special-thanks {
    border-color: #ffd700;
    background: #fffdf0;
    position: relative;
    overflow: hidden;
}

.comment-card.special-thanks::before {
    content: 'SPECIAL THANKS';
    position: absolute;
    top: 0;
    right: 0;
    background: #ffd700;
    color: #333;
    font-size: 0.7rem;
    font-weight: bold;
    padding: 2px 10px;
    border-bottom-left-radius: 8px;
}



/* ==========================================================================
   Responsive (SP)
   ========================================================================== */
.event-footer-nav {
    margin-top: 60px;
    text-align: center;
    margin-bottom: 20px;
}

.btn-back-list {
    display: inline-block;
    padding: 12px 40px;
    background: #888;
    color: #fff;
    text-decoration: none;
    border-radius: 50px;
    font-weight: bold;
    font-size: 1.1rem;
    transition: all 0.3s;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.btn-back-list:hover {
    background: #666;
    transform: translateY(-2px);
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.15);
}

@media screen and (max-width: 768px) {
    .event-header {
        grid-template-columns: 1fr;
        /* Stack vertically */
    }

    .event-header-text h1.event-title {
        font-size: 1.4rem;
    }

    .archive-title-img {
        width: 70%;
    }

    h2.archive-title {
        font-size: 1rem;
    }

    .archive-subtitle,
    .event-notice,
    .discord-btn-wrapper {
        text-align: left;
    }

    .mvp-card-container {
        flex-direction: column;
    }

    .mvp-card {
        max-width: 100%;
        width: 100%;
        box-sizing: border-box;
    }

    .event-comments {
        grid-template-columns: 1fr;
    }



    .event-card-grid {
        grid-template-columns: 1fr;
        /* 1 col on mobile */
    }

    .event-summary-list div {
        grid-template-columns: 1fr;
        justify-items: center;
        /* Stack layout for summary items if needed */
    }

    .content-title {
        font-size: 1.5rem;
        text-align: center;
        margin: 20px auto;
    }

    .event-summary-list dt {
        width: 80%;
        margin-bottom: 5px;
        margin-right: 0;
        display: inline-block;
    }

    .event-summary-list dd {
        width: fit-content;
        text-align: left;
    }
}

/* ==========================================================================
   YouTube Archive Button
   ========================================================================== */
.btn-archive {
    display: inline-flex;
    align-items: center;
    background: #11caeb;
    color: #fff;
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    font-size: 0.95rem;
    transition: background 0.3s, transform 0.2s;
    margin-top: 15px;
    margin-bottom: 20px;
}

.btn-archive:hover {
    background: #085cf7;
    transform: translateY(-2px);
    color: #fff;
}

.btn-archive i {
    margin-right: 10px;
    font-size: 1.2rem;
}

/* ==========================================================================
   Team Display
   ========================================================================== */
.team-display-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.team-block {
    background: #fff;
    border: 2px solid #ddd;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
}

.team-name {
    font-size: 1.2rem;
    font-weight: bold;
    text-align: center;
    margin-top: 0;
    margin-bottom: 10px;
    color: #444;
    border-bottom: 2px solid #eee;
    /* Underline for team name */
    padding-bottom: 5px;
}

.team-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
}

/* Override/Adjust existing member-list for inside teams */
ul.member-list.team-list {
    display: flex;
    flex-direction: column;
    /* Stack members vertically in team card */
    gap: 8px;
    padding: 0;
}

ul.member-list.team-list li {
    width: auto;
    /* Allow full width of container */
    margin: 0;
    border: 1px solid #eee;
    /* Lighter border inside team */
    background: #fdfdfd;
    border-radius: 6px;
    /* Smaller radius */
}

/* ==========================================================================
   Winning Team & Result Section
   ========================================================================== */

/* Subtitle for Gallery Sections */
h3.gallery-subtitle {
    font-size: 1.5rem;
    font-weight: bold;
    border-left: 6px solid #ffd700;
    /* Gold accent */
    padding-left: 15px;
    margin-top: 50px;
    margin-bottom: 30px;
    color: #444;
    background: linear-gradient(to right, rgba(255, 215, 0, 0.1), transparent);
    padding-block: 5px;
}

/* Result Screen */
.event-result {
    margin-bottom: 50px;
}

.result-image-container {
    width: 100%;
    border: 4px solid #444;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.result-image-container img {
    width: 100%;
    height: auto;
    display: block;
}

/* Winning Team Section */
.event-winner-section {
    margin-bottom: 60px;
    text-align: center;
    background: #fffbef;
    /* Light gold tint bg */
    padding: 30px;
    border-radius: 12px;
    border: 2px solid #ffd700;
    position: relative;
    overflow: hidden;
}

/* Confetti decoration effect (optional simple CSS only) */
.event-winner-section::before,
.event-winner-section::after {
    content: '🎊';
    font-size: 3rem;
    position: absolute;
    top: 20px;
    opacity: 0.5;
}

.event-winner-section::before {
    left: 20px;
    transform: rotate(-15deg);
}

.event-winner-section::after {
    right: 20px;
    transform: rotate(15deg);
}

.winner-team-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    max-width: 600px;
    margin: 0 auto;
}

/* Winner Mode Team Block */
.team-block.winner-mode {
    transform: scale(1.1);
    border: 4px solid #ffd700;
    /* Gold border */
    box-shadow: 0 10px 25px rgba(255, 215, 0, 0.4);
    z-index: 1;
    background: #fff;
    width: 100%;
    max-width: 350px;
}

.team-block.winner-mode .team-name {
    color: #d4af37;
    /* Darker gold text */
    font-size: 1.5rem;
    border-bottom-color: #ffd700;
}

.team-block.winner-mode .team-name::before {
    content: '👑 ';
}

.winner-comment {
    margin-top: 15px;
    background: #fff;
    padding: 15px 25px;
    border-radius: 50px;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.05);
    font-weight: bold;
    color: #555;
    position: relative;
}

.winner-comment::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 0 10px 10px 10px;
    border-style: solid;
    border-color: transparent transparent #fff transparent;
}

/* Responsive adjustments */
@media screen and (max-width: 768px) {
    .team-display-container {
        grid-template-columns: 1fr;
    }

    .team-block.winner-mode {
        transform: scale(1);
        /* Reset scale on mobile */
        width: 90%;
    }

    .event-winner-section::before,
    .event-winner-section::after {
        font-size: 2rem;
        top: 10px;
    }
}

/* ==========================================================================
   Result Grid (gallery-grid-result)
   ========================================================================== */
.gallery-grid-result {
    display: flex;
    gap: 16px;
    list-style: none;
    padding: 0;
    margin: 30px 0;
    align-items: stretch;
}

.gallery-grid-result li {
    flex: 1 1 0;
    min-width: 0;
}

.result-card {
    display: flex;
    flex-direction: column;
    margin: 0;
    border: 2px solid #ddd;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.08);
    height: 100%;
}

.result-card a {
    display: block;
    flex: 1 1 auto;
    overflow: hidden;
    line-height: 0;
}

.result-card a img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}

.result-card a:hover img {
    transform: scale(1.03);
}

.result-rank {
    display: block;
    text-align: center;
    font-size: 1rem;
    font-weight: bold;
    background: #f0f0f0;
    padding: 6px 10px;
    color: #333;
    letter-spacing: 0.05em;
}

.result-team-name {
    display: block;
    text-align: center;
    font-size: 0.95rem;
    font-weight: bold;
    padding: 8px 10px;
    background: #fff;
    color: #444;
    border-top: 1px solid #eee;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media screen and (max-width: 768px) {
    .gallery-grid-result {
        flex-direction: column;
    }
}

/* ==========================================================================
   Staff Credit (参加者セクション内)
   ========================================================================== */
.event-staff-credit {
    margin-top: 20px;
    text-align: right;
    font-size: 0.85rem;
    color: #777;
    letter-spacing: 0.03em;
    border-top: 1px dashed #ddd;
    padding-top: 12px;
}