:root {
    --accent: #c0392b;
    --bg: #faf8f5;
    --text: #222;
    --muted: #666;
}
* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
    background: var(--bg);
    color: var(--text);
}

.hero {
    position: relative;
    height: 38vh;
    min-height: 260px;
    max-height: 380px;
    background: #222 url('./images/header.jpg') center 40% / cover no-repeat;
    display: flex;
    align-items: flex-end;
}
.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(10,10,10,0.15) 0%, rgba(10,10,10,0.3) 50%, rgba(10,10,10,0.8) 100%);
}
.hero-content {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 960px;
    margin: 0 auto;
    padding: 24px 24px 32px;
    box-sizing: border-box;
}
.hero-eyebrow {
    margin: 0 0 8px;
    font-size: 11px;
    font-weight: bold;
    letter-spacing: 0.22em;
    color: rgba(255,255,255,0.78);
}
.hero h1 {
    margin: 0 0 8px;
    font-size: clamp(22px, 4.5vw, 32px);
    color: #fff;
    letter-spacing: 0.04em;
    text-shadow: 0 2px 16px rgba(0,0,0,0.35);
}
.hero-sub {
    margin: 0;
    font-size: 13px;
    color: rgba(255,255,255,0.88);
}
.hero-sub a { color: #fff; text-decoration: underline; font-weight: bold; }
.hero-sub a:hover { color: rgba(255,255,255,0.8); }
.back-link {
    display: inline-block;
    margin-bottom: 14px;
    font-size: 13px;
    color: rgba(255,255,255,0.85);
    text-decoration: none;
}
.back-link:hover { text-decoration: underline; color: #fff; }

main {
    max-width: 960px;
    margin: 0 auto;
    padding: 40px 20px 60px;
}

.year-group { margin-bottom: 36px; }
.year-heading {
    font-size: 18px;
    border-left: 4px solid var(--accent);
    padding-left: 10px;
    margin: 0 0 16px;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
}

.video-card {
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: white;
    border: 1px solid #eee;
    border-radius: 10px;
    padding: 10px;
    cursor: pointer;
    text-align: left;
    font-family: inherit;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    transition: transform 0.15s, box-shadow 0.15s;
}
.video-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.1);
}

.video-thumb-wrap {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 6px;
    overflow: hidden;
    background: #ddd;
}
.video-thumb-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.play-badge {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(0,0,0,0.6);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    padding-left: 3px;
}

.video-title {
    font-size: 13px;
    line-height: 1.4;
    color: #333;
}

.error { text-align: center; color: #c0392b; padding: 40px 0; }

/* 動画モーダル */
.modal {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.85);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
}
.modal.hidden { visibility: hidden; opacity: 0; pointer-events: none; }
.video-modal-content {
    position: relative;
    width: min(90vw, 960px);
}
.video-frame-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
}
.video-frame-wrap iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
    border-radius: 6px;
}
.close-btn {
    position: absolute;
    top: -36px;
    right: 0;
    color: white;
    font-size: 28px;
    background: rgba(0,0,0,0.5);
    border-radius: 50%;
    width: 30px;
    height: 30px;
    line-height: 30px;
    text-align: center;
    cursor: pointer;
}
