/* ===== 基本 ===== */
html {
    scroll-behavior: smooth;
}
body {
    font-family: Arial, sans-serif;
    margin: 0;
    background: #f5f7fb;
    line-height: 1.6;
    overflow-x: hidden;
}
a {
    text-decoration: none;
    color: inherit;
}
* {
    box-sizing: border-box;
    transition: color .25s ease, background-color .25s ease, transform .3s ease, box-shadow .3s ease;
}

/* ===== ヘッダー ===== */
header {
    position: relative;
    height: 320px;
    background: linear-gradient(135deg,#4CAF50,#2e8b57);
    color: white;
    overflow: hidden;
    border-radius: 0;
}

/* 背景ロゴ */
.header-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}
.header-bg img {
    position: absolute;
    width: 900px;
    opacity: 0.05;
    filter: blur(1px);
}
.bg1 {
    transform: rotate(-25deg);
    top: -200px;
    left: -200px;
    animation: bgMove1 18s ease-in-out infinite;
}
.bg2 {
    transform: rotate(25deg);
    bottom: -200px;
    right: -200px;
    animation: bgMove2 22s ease-in-out infinite;
}
@keyframes bgMove1 {
    0% { transform: rotate(-25deg) translateY(0); }
    50% { transform: rotate(-25deg) translateY(40px); }
    100% { transform: rotate(-25deg) translateY(0); }
}
@keyframes bgMove2 {
    0% { transform: rotate(25deg) translateY(0); }
    50% { transform: rotate(25deg) translateY(-40px); }
    100% { transform: rotate(25deg) translateY(0); }
}

/* ===== ヘッダー文字 ===== */
.header-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 2;
}
.main-title {
    margin: 0;
    font-size: 42px;
    font-weight: bold;
    color: white;
}
#countdown,
#countdown-message {
    margin-top: 10px;
    font-size: 22px;
    font-weight: bold;
}

/* ===== ナビ（ヘッダー下 + sticky） ===== */
nav {
    position: sticky;
    top: 0; /* スクロールで画面上に固定 */
    width: 100%;
    background: rgba(0,0,0,0.75);
    padding: 12px 0;
    z-index: 2000;
    transform: translateY(-30px);
    opacity: 0;
    animation: navSlide 0.8s forwards;
    animation-delay: 0.5s;
}
@keyframes navSlide {
    to { transform: translateY(0); opacity: 1; }
}
nav ul {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 0;
    padding: 0;
    list-style: none;
}
nav a {
    color: white;
    font-weight: bold;
    padding: 8px 14px;
    border-radius: 6px;
}
nav a:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-2px);
}

/* ===== メイン ===== */
main {
    padding: 20px;
    max-width: 1000px;
    margin: auto;
    margin-top: 20px;
    position: relative;
    z-index: 5;
}

/* ===== セクション ===== */
section {
    padding: 40px 25px;
    margin-bottom: 30px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
}
section h2 {
    margin-top: 0;
    border-bottom: 3px solid #4CAF50;
    display: inline-block;
    padding-bottom: 5px;
}

/* ===== グリッド ===== */
.grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

/* ===== カード ===== */
.card,
.post {
    flex: 1 1 calc(33% - 20px);
    min-width: 250px;
    padding: 15px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    text-align: center;
}
.card:hover,
.post:hover {
    transform: translateY(-6px);
    box-shadow: 0 10px 22px rgba(0,0,0,0.15);
}

/* ===== 画像 ===== */
.card img,
.post img {
    width: 100%;
    max-width: 600px;
    border-radius: 10px;
    cursor: pointer;
}
.map-img{
    width:100%;
    max-width:800px;
    display:block;
    margin:auto;
    border-radius:12px;
}

/* ===== 動画 ===== */
.video-wrapper {
    position: relative;
    width: 100%;
    padding-top: 56.25%;
}
.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
    border-radius: 12px;
}

/* ===== フッター ===== */
footer {
    background: #f8f9fa;
    padding: 40px 20px;
    border-top: 1px solid #ddd;
    font-size: 14px;
    text-align: center;
    color: #555;
}
.github-icon {
    width: 20px;
    vertical-align: middle;
    margin-right: 5px;
}

/* ===== モーダル ===== */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.85);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 3000;
}
.modal.show {
    display: flex;
}
.modal-inner {
    position: relative;
    max-width: 95%;
    max-height: 95%;
}
.modal-content {
    max-width: 90vw;
    max-height: 85vh;
    border-radius: 12px;
}
.close {
    position: absolute;
    top: -15px;
    right: -15px;
    background: rgba(0,0,0,0.6);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    cursor: pointer;
    color: white;
}

/* ===== レスポンシブ ===== */
@media(max-width: 768px) {
    nav { top: 0; }
    .grid { flex-direction: column; }
    .card, .post { flex: 1 1 100%; }
    section { padding: 30px 15px; }
    header { height: 250px; }
    .main-title { font-size: 30px; }
}
@media(max-width: 480px) {
    nav { top: 0; }
    header { height: 200px; }
    .main-title { font-size: 24px; }
    #countdown { font-size: 18px; }
}
