@charset "utf-8";
/* CSS Document */

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
    font-size: 16px;
    line-height: 1.8;
    color: #333;
    background-color: #fff;
}

img {
    max-width: 100%;
    height: auto;
}

a {
    color: #0066cc;
    text-decoration: underline;
}

a:hover {
    color: #004499;
}

/* Container */
#wrapper {
    width: 100%;
    margin: 0 auto;
    background-color: #fff;
}

/* Header */
#header {
    background-color: #fff;
    color: #333;
    padding: 15px 0;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 2000;
}

.header-content {
    display: flex;
    align-items: center;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
}

#header .logo {
    margin-right: 20px;
}

#header .logo img {
    height: 60px;
    width: auto;
}

#header h1 {
    font-size: 28px;
    font-weight: bold;
    flex: 1;
    font-family: "Times New Roman", "Yu Mincho", "Hiragino Mincho ProN", "Hiragino Mincho Pro", "HG明朝E", serif;
}

#header h1 a {
    color: #333;
    text-decoration: none;
}

/* 文化庁サイトへのリンク */
#header p#bunkacho {
    font-size: 12px;
    position: absolute;
    top: 0;
    left: calc(50% + 380px);
    margin: 0;
    padding: 10px 20px;
    background: #f7f7f7;
    border: 1px #e6e2e2 solid;
    border-top: none;
    border-bottom-right-radius: 25px;
    border-bottom-left-radius: 25px;
    z-index: 2100;
}

#header p#bunkacho a {
    color: #333;
    text-decoration: none;
    font-size: 12px;
}

#header p#bunkacho a:hover {
    color: #0066cc;
    text-decoration: underline;
}

/* ハンバーガーメニュー */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 10px;
    background-color: #999;
    border-radius: 4px;
    position: fixed;
    right: 20px;
    top: 20px;
    z-index: 2101;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: #fff;
    margin: 2px 0;
    transition: 0.3s;
    display: block;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
}

/* Navigation */
#gnav {
    position: fixed;
    top: 90px;
    left: 0;
    right: 0;
    z-index: 1999;
    margin-bottom: 0;
    background: transparent;
    display: block !important;
    visibility: visible !important;
}

.nav-container {
    width: 100%;
    background: linear-gradient(135deg, #c41e3a 0%, #d2691e 100%);
    min-height: 48px;
}

#gnav ul {
    display: flex;
    justify-content: center;
    list-style: none;
    padding: 0;
    margin: 0;
    flex-wrap: wrap;
}

#gnav li {
    margin: 0;
    border-right: 1px solid rgba(255,255,255,0.3);
    flex: 0 0 auto;
}

#gnav li:last-child {
    border-right: none;
}

#gnav li a {
    display: block;
    padding: 12px 20px;
    color: #fff;
    font-weight: normal;
    font-size: 14px;
    text-decoration: none;
    white-space: nowrap;
}

#gnav li a:hover {
    background-color: rgba(255,255,255,0.1);
    color: #fff;
}

/* 現在のページ表示 */
#gnav li a.current {
    background-color: rgba(255,255,255,0.2);
    font-weight: bold;
}

/* パンくずリスト */
.breadcrumb {
    background-color: #f8f8f8;
    border-bottom: 1px solid #ddd;
    padding: 10px 0;
    position: relative;
    z-index: 100;
}

.breadcrumb-inner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
    font-size: 12px;
    color: #666;
}

.breadcrumb a {
    color: #0066cc;
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

/* ページタイトル */
.page-title {
    background-color: #e0e0e0;
    padding: 20px 0;
    margin-bottom: 30px;
    position: relative;
    z-index: 100;
}

.page-title-inner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

.page-title h2 {
    font-size: 24px;
    font-weight: bold;
    color: #333;
    margin: 0;
    font-family: "Times New Roman", "Yu Mincho", "Hiragino Mincho ProN", "Hiragino Mincho Pro", "HG明朝E", serif;
}

/* Main Visual Area - Slideshow（トップページ用） */
.main-visual {
    max-width: 1000px;
    margin: 0 auto;
    height: 300px;
    position: relative;
    overflow: hidden;
}

.slide-container {
    width: 100%;
    height: 100%;
    position: relative;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.slide.active {
    opacity: 1;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* CTA Section（トップページ用） */
.cta-section {
    text-align: center;
    padding: 30px 20px;
    background-color: #fff;
}

.cta-button {
    display: inline-block;
    background-color: #c41e3a;
    color: #fff;
    padding: 15px 60px;
    font-size: 24px;
    font-weight: bold;
    text-decoration: none;
    border-radius: 40px;
    min-width: 400px;
    transition: all 0.3s ease;
}

.cta-button:hover {
    background-color: #a01729;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(196, 30, 58, 0.3);
}

/* CTAボタンのホバー効果 */
.cta-button.hover-effect {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(196, 30, 58, 0.3);
    transition: all 0.3s ease;
}

/* Contents Area */
#contents {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px 0;
    position: relative;
    z-index: 100;
}

/* コンテンツ共通 */
.content-inner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 2カラムレイアウト（トップページ用） */
.content-wrapper {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}

/* セクション共通 */
.content-section {
    margin-bottom: 40px;
}

.section-title {
    font-size: 20px;
    font-weight: bold;
    color: #333;
    margin-bottom: 15px;
    border-left: 6px solid #c41e3a;
    padding-left: 15px;
}

.section-content {
    font-size: 14px;
    line-height: 1.8;
    color: #333;
}

.section-content p {
    margin-bottom: 15px;
}

.section-content p:last-child {
    margin-bottom: 0;
}

/* Event Section（トップページ用） */
.event-section {
    flex: 1;
    background-color: #fff;
    padding: 0;
}

.event-section h2 {
    font-size: 18px;
    margin-bottom: 15px;
    color: #333;
    font-weight: bold;
    border-left: 6px solid #c41e3a;
    padding-left: 15px;
}

.event-description {
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 20px;
}

.event-table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background-color: #f5f5f5;
}

.event-table th {
    background-color: #e0e0e0;
    padding: 10px;
    text-align: center;
    font-weight: bold;
    border: 1px solid #ccc;
    width: 200px;
}

.event-table td {
    padding: 10px;
    border: 1px solid #ccc;
    background-color: #fff;
}

.event-status {
    background-color: #fff;
    color: #333;
    padding: 10px;
    text-align: center;
    font-weight: bold;
    font-size: 14px;
    border: 1px solid #ddd;
    margin: 15px 0;
}

.download-links {
    margin-top: 15px;
}

.download-links p {
    margin-bottom: 5px;
    font-size: 14px;
}

.download-links a {
    color: #0066cc;
    text-decoration: underline;
}

.download-links a:hover {
    color: #004499;
}

/* Information Section（トップページ用） */
#news {
    flex: 1;
    background-color: #fff;
    padding: 0;
}

#news h2 {
    font-size: 18px;
    color: #333;
    margin-bottom: 20px;
    font-weight: bold;
    border-left: 6px solid #c41e3a;
    padding-left: 15px;
}

.news-list {
    margin: 0;
    height: 400px;
    overflow-y: scroll;
    border: 1px solid #ddd;
    background-color: #fff;
    scrollbar-width: thin;
    scrollbar-color: #999 #f1f1f1;
}

/* Webkit browsers (Chrome, Safari, Edge) - スクロールバーをグレーに */
.news-list::-webkit-scrollbar {
    width: 8px;
}

.news-list::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.news-list::-webkit-scrollbar-thumb {
    background: #999;
    border-radius: 4px;
}

.news-list::-webkit-scrollbar-thumb:hover {
    background: #666;
}

/* 日付と内容をセットで交互に背景色変更 */
.news-list dt:nth-of-type(odd),
.news-list dt:nth-of-type(odd) + dd {
    background-color: #fff;
}

.news-list dt:nth-of-type(even),
.news-list dt:nth-of-type(even) + dd {
    background-color: #f9f9f9;
}

.news-list dt {
    font-size: 12px;
    color: #666;
    font-weight: normal;
    padding: 10px 0px 0px 10px;
    margin: 0;
    border-bottom: none;
}

.news-list dd {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    padding: 6px 0px 10px 10px;
    border-bottom: 1px solid #eee;
}

.news-list dd:last-child {
    border-bottom: none;
}

/* Footer */
#footer {
    background-color: #333;
    color: #fff;
    padding: 15px 0;
    text-align: center;
    margin-top: 20px;
}

#copy {
    font-size: 12px;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Page Top Button */
#pagetop {
    text-align: right;
    margin: 30px 0 0 0;
    padding-right: 20px;
}

#pagetop a {
    color: #0066cc;
    text-decoration: underline;
    font-size: 12px;
}

#pagetop a:hover {
    color: #004499;
}

/* フェードイン効果用 */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* 年度リンク */
.year-link {
    margin-bottom: 20px;
    font-size: 16px;
    font-weight: bold;
}

.year-link a {
    color: #0066cc;
    text-decoration: underline;
}

.year-link a:hover {
    color: #004499;
}

/* ユーティリティクラス */
.t-c {
    text-align: center !important;
}

.t-l {
    text-align: left !important;
}

.t-r {
    text-align: right !important;
}

.mb-20 {
    margin-bottom: 20px !important;
}

.mb-50 {
    margin-bottom: 50px !important;
}

/* コンテンツが固定ヘッダーに隠れないように余白を確保 */
body {
    padding-top: 140px;
}

/* レスポンシブ対応 */
@media (max-width: 1040px) {
    #header p#bunkacho {
        right: 20px;
        left: auto;
    }
    
    .content-wrapper {
        padding: 20px;
    }
}

/* デスクトップでの確実な表示 */
@media (min-width: 769px) {
    .hamburger {
        display: none !important;
    }
    
    #gnav {
        display: block !important;
        visibility: visible !important;
    }
    
    #gnav ul {
        display: flex !important;
        opacity: 1 !important;
        transform: none !important;
        position: static !important;
        background: transparent !important;
        box-shadow: none !important;
    }
}

@media (max-width: 768px) {
    body {
        padding-top: 120px; /* ヘッダー + ナビの高さを考慮して増加 */
    }
    
    /* ヘッダーコンテンツは横並びのまま */
    .header-content {
        flex-direction: row;
        text-align: left;
        gap: 5px;
        padding: 0 20px;
        justify-content: space-between;
        margin-top: 20px;
    }
    
    #header h1 {
        font-size: 20px;
        flex: 1;
    }
    
    /* 文化庁リンクは右上に表示 */
    #header p#bunkacho {
        display: block;
        right: 20px;
        left: auto;
        top: 0;
    }
    
    /* ハンバーガーメニューを表示 */
    .hamburger {
        display: flex !important;
        top: 50px;
        right: 20px;
    }
    
    /* ナビゲーション: 全体は常に表示 */
    #gnav {
        display: block !important;
        visibility: visible !important;
        top: 0;
    }
    
    /* モバイル用ナビゲーションメニュー */
    #gnav ul {
        flex-direction: column;
        position: fixed;
        top: 120px; /* ヘッダーの高さに合わせて調整 */
        left: 0;
        right: 0;
        background: linear-gradient(135deg, #c41e3a 0%, #d2691e 100%);
        display: none !important;
        z-index: 2099;
        box-shadow: 0 2px 10px rgba(0,0,0,0.3);
        border-radius: 0;
        opacity: 0;
        transform: translateY(-10px);
        transition: all 0.3s ease;
        max-height: 0;
        overflow: hidden;
    }
    
    /* アクティブ状態のメニュー */
    #gnav ul.active {
        display: flex !important;
        opacity: 1 !important;
        transform: translateY(0) !important;
        max-height: 500px !important;
    }
    
    #gnav li {
        border-right: none;
        border-bottom: 1px solid rgba(255,255,255,0.3);
        width: 100%;
    }
    
    #gnav li:last-child {
        border-bottom: none;
    }
    
    #gnav li a {
        padding: 15px 20px;
        text-align: center;
        width: 100%;
        display: block;
    }
    
    /* パンくずリストの位置調整 */
    .breadcrumb {
        margin-top: 0;
        position: relative;
        z-index: 100;
    }
    
    /* ページタイトルの位置調整 */
    .page-title {
        margin-top: 0;
        position: relative;
        z-index: 100;
    }
    
    /* コンテンツエリアの位置調整 */
    #contents {
        margin-top: 0;
        position: relative;
        z-index: 100;
    }
    
    .main-visual {
        height: 200px;
    }
    
    .cta-button {
        min-width: 300px;
        padding: 12px 40px;
    }
    
    .content-wrapper {
        flex-direction: column;
        gap: 20px;
    }
    
    .event-table th {
        font-size: 12px;
    }
    
    .event-table td {
        font-size: 12px;
    }
    
    .news-list {
        height: 300px;
    }
    
    .page-title h2 {
        font-size: 20px;
    }
    
    .section-title {
        font-size: 18px;
    }
    
    .breadcrumb-inner,
    .page-title-inner,
    .content-inner {
        padding: 0 15px;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 14px;
        padding-top: 100px; /* さらに小さい画面での調整 */
    }
    
    #header h1 {
        font-size: 16px;
    }
    
    #header .logo img {
        height: 50px;
    }
    
    #header p#bunkacho {
        font-size: 9px;
        padding: 6px 15px;
    }
    
    .hamburger {
        display: flex !important;
        top: 10px;
        right: 10px;
        padding: 8px;
    }
    
    .hamburger span {
        width: 20px;
        height: 2px;
    }
    
    #gnav ul {
        top: 100px; /* 小さい画面でのメニュー位置調整 */
    }
    
    .cta-button {
        font-size: 16px;
        padding: 12px 30px;
        min-width: 280px;
    }
    
    .main-visual {
        height: 150px;
    }
    
    #contents {
        padding: 15px;
    }
    
    .news-list {
        height: 250px;
    }
    
    /* 確実な表示設定 */
    #gnav {
        display: block !important;
        visibility: visible !important;
    }
}