/* --- Reset & Base --- */
:root {
    --primary-color: #f57c00; /* 赤みのあるメインオレンジ */
    --secondary-color: #ffb74d; /* 明るく優しいオレンジ */
    --accent-color: #3498db; /* アクセントの青 */
    --text-color: #333;
    --bg-color-light: #fefaf5; /* オレンジに合うように少しクリーム色に */
    --white-color: #fff;
    --header-height: 70px;
}

html {
    box-sizing: border-box;
    scroll-behavior: smooth;
}

*, *::before, *::after {
    box-sizing: inherit;
}

body {
    font-family: 'Noto Sans JP', sans-serif;
    font-size: 14px; /* サイト全体の基本フォントサイズをさらに調整 */
    line-height: 1.7;
    color: var(--text-color);
    background-color: var(--white-color);
    margin: 0;
    padding-top: var(--header-height);
    line-break: strict; /* 日本語の改行ルールを厳密にする */
    word-break: keep-all; /* 単語の途中で改行しない */
}

p {
    orphans: 2; /* 段落の末尾が新しい段の先頭に1行だけ残るのを防ぐ */
    widows: 2;  /* 段落の先頭が前の段の末尾に1行だけ残るのを防ぐ */
}

a {
    text-decoration: none;
    color: var(--secondary-color);
    transition: color 0.3s ease;
}

a:hover {
    color: var(--primary-color);
}

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

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- Header --- */
.header {
    background-color: var(--white-color);
    height: var(--header-height);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    font-family: 'Poppins', sans-serif;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
}

.header nav {
    display: flex;
    align-items: baseline; /* 垂直方向の揃えを、中央から文字のベースライン基準に変更 */
    gap: 25px;
}

.header nav ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    align-items: center;
    gap: 25px;
}

.header nav a {
    font-weight: 700;
    color: var(--text-color);
    padding: 5px 0;
    position: relative;
}

.header nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.header nav a:hover::after {
    width: 100%;
}

.nav-cta {
    background-color: var(--accent-color);
    color: var(--white-color) !important;
    padding: 8px 20px !important;
    border-radius: 50px;
    transition: background-color 0.3s ease;
}

.nav-cta:hover {
    background-color: #e67e22;
}
.nav-cta::after {
    display: none;
}

/* Hamburger Menu (PCでは非表示) */
.hamburger-menu {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 24px;
    position: relative;
    z-index: 1001;
}

.hamburger-menu span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--text-color);
    position: absolute;
    left: 0;
    transition: all 0.3s ease;
}

.hamburger-menu span:nth-child(1) { top: 0; }
.hamburger-menu span:nth-child(2) { top: 11px; }
.hamburger-menu span:nth-child(3) { top: 22px; }

.hamburger-menu.active span:nth-child(1) {
    transform: translateY(11px) rotate(45deg);
}
.hamburger-menu.active span:nth-child(2) {
    opacity: 0;
}
.hamburger-menu.active span:nth-child(3) {
    transform: translateY(-11px) rotate(-45deg);
}


/* --- Hero Character --- */
.hero-character {
    position: absolute;
    bottom: 0;
    right: 5%;
    max-width: 350px;
    height: auto;
    z-index: 3; /* hero-content(z-index:2)より手前に */
}

/* --- Hero Section --- */
#hero {
    background-image: url('images/main_visual.jpg');
    background-size: cover;
    background-position: center;
    color: var(--white-color);
    text-align: center;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - var(--header-height));
    padding: 100px 20px;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: black;
    opacity: 0.7;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    padding-top: 50px; /* コンテンツ全体を少し下に移動 */
}

.hero-title {
    font-family: 'Poppins', sans-serif;
    /* font-size: 2.5rem; */
    font-weight: 700;
    margin: 0 0 20px;
    line-height: 1.2;
}

.main-title {
    display: block;
    font-size: 4.5rem;
    position: relative;
    top: -20px; /* 少し上に移動 */
    margin-bottom: 10px;
    line-height: 1.1;
}

.sub-catchphrase {
    display: block;
    font-size: 2.0rem;
    line-height: 1.4;
    opacity: 0.85;
    position: relative; /* 相対位置指定 */
    top: -80px; /* もっと上に移動 */
}

.hero-subtitle {
    font-size: 1.5rem;
    margin: 0 0 30px;
    opacity: 0.9;
}

.hero-sub-copy {
    font-size: 1.1rem;
    margin-bottom: 40px;
}

.event-info-text {
    font-size: 1.5rem; /* 日時を大きく */
    opacity: 0.9;
    /* color: var(--accent-color); */ /* 色を元に戻すためコメントアウト */
    /* text-shadow: 1px 1px 3px rgba(0,0,0,0.5); */ /* 影を削除 */
    background-color: rgba(255, 255, 255, 0.2); /* 半透明の白背景 */
    padding: 10px 40px; /* 左右のパディングを広げる */
    border-radius: 5px; /* 角を丸く */
    display: block; /* ブロック要素にする */
    margin: 0 auto 20px auto; /* 中央揃えと下のマージン */
    text-align: center; /* 中央揃え */
    margin-top: -20px; /* 少し上に移動 */
    white-space: nowrap; /* 強制的に改行させない */
}

.event-label {
    font-size: 1.0em; /* 文字を大きく */
    opacity: 0.7;
    display: block; /* 縦並びにする */
    margin-bottom: 5px; /* 下に少し余白 */
}

.event-line {
    display: block; /* 縦並びにする */
    line-height: 1.2; /* 行間を調整 */
    margin-left: 20px; /* 右にインデント */
}

.event-number {
    font-size: 1.8em; /* 親要素の1.8倍の大きさ */
    font-weight: 700; /* 太字にする */
}

.cta-button {
    display: inline-block;
    background-color: var(--accent-color);
    color: var(--white-color);
    padding: 15px 40px;
    border-radius: 50px;
    font-size: 1.2rem;
    font-weight: 700;
    transition: transform 0.3s ease, background-color 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.cta-button:hover {
    background-color: #e67e22;
    transform: translateY(-3px);
}

/* --- Content Sections --- */
.content-section {
    padding: 80px 0;
}

.bg-light {
    background-color: var(--bg-color-light);
}

.section-title {
    font-family: 'Poppins', sans-serif;
    font-size: 2.8rem;
    font-weight: 700;
    text-align: center;
    margin: 0 0 30px; /* ここ */
    color: var(--primary-color);
}

.section-title span {
    display: block;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--secondary-color);
    margin-bottom: 5px;
}

.section-lead {
    font-size: 1.1rem;
    text-align: center;
    max-width: 700px;
    margin: -40px auto 50px;
    line-height: 1.8;
}

/* --- About Section --- */
.features {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.feature-item {
    background: var(--white-color);
    padding: 30px;
    text-align: center;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.feature-icon {
    width: 70px;
    height: 70px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.feature-icon img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.feature-item h3 {
    font-size: 1.4rem;
    margin: 0 0 10px;
    color: var(--primary-color);
}

/* --- Services Section --- */
.service-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.service-item {
    background: var(--white-color);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.service-item img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
}

.service-content {
    padding: 25px;
}

.service-content h3 {
    font-size: 1.3rem;
    margin: 0 0 10px;
    color: var(--primary-color);
}

/* --- Merits (Schedule) Section --- */
.schedule-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 30px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
    border-radius: 10px;
    overflow: hidden;
}

.schedule-table th, .schedule-table td {
    padding: 20px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.schedule-table thead th {
    background-color: var(--primary-color);
    color: var(--white-color);
    font-weight: 700;
    font-size: 1.1rem;
}

.schedule-table tbody tr:nth-child(even) {
    background-color: var(--bg-color-light);
}

.schedule-table tbody tr:hover {
    background-color: #e9ecef;
}

.schedule-table td:first-child {
    font-weight: 700;
    color: var(--primary-color);
}

#merits {
    padding-bottom: 240px; /* 余白をさらにさらに増やす */
}

/* --- CTA Section --- */
.cta-section {
    background-color: var(--primary-color);
    color: var(--white-color);
    padding: 100px 0; /* 上下のパディングをさらに増やす */
    text-align: center;
}

.cta-section .section-title,
.cta-section .section-title span {
    color: var(--white-color);
}

.event-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    text-align: left;
    margin-bottom: 50px;
    margin-top: 20px; /* 少し下に移動 */
}

.event-info h3 {
    font-size: 1.8rem;
    border-bottom: 2px solid var(--white-color);
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.event-info p {
    margin: 10px 0;
    font-size: 1.1rem;
}

.event-map iframe {
    width: 100%;
    height: 100%;
    min-height: 250px;
    border-radius: 10px;
}

.cta-note {
    margin-top: 10px; /* ここ */
    opacity: 0.8;
    position: relative;
    top: -10px; /* 少し上に移動 */
}

/* --- Food Section --- */
.food-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

#food .section-title {
    text-align: left;
    margin-bottom: 30px;
}

#food p {
    text-align: left;
}

.food-image img {
    width: 100%;
    border-radius: 10px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

/* --- Footer --- */
.footer {
    background-color: #2c3e50;
    color: #ecf0f1;
    padding: 60px 0 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    margin-bottom: 40px;
    flex-wrap: wrap;
    gap: 30px;
}

.company-info, .footer-nav {
    flex: 1;
    min-width: 250px;
}

.footer h4 {
    font-size: 1.3rem;
    color: var(--white-color);
    margin-bottom: 20px;
    border-bottom: 1px solid var(--secondary-color);
    padding-bottom: 10px;
}

.footer p, .footer li {
    margin: 5px 0;
    opacity: 0.8;
}

.footer ul {
    list-style: none;
    padding: 0;
}

.footer a {
    color: #ecf0f1;
}

.footer a:hover {
    color: var(--white-color);
    text-decoration: underline;
}

.copy-right {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #34495e;
    opacity: 0.7;
    font-size: 0.9rem;
}

/* --- Scroll Animation --- */
.content-section {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.content-section.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- Call-to-Action Button Customization (Green) --- */
.nav-cta,
.hero-cta,
.final-cta {
    background-color: #25D366 !important; /* CTA Green */
    position: relative;
    top: -20px; /* 少し上に移動 */
    margin-top: 10px; /* 上の要素との間隔 */
    margin-bottom: 30px; /* 下の要素との間隔 */
}

.nav-cta:hover,
.hero-cta:hover,
.final-cta:hover {
    background-color: #1DA851 !important; /* Darker CTA Green */
}


/* --- Final CTA Button Customization --- */
.final-cta {
    padding: 20px 60px; /* パディングを大きく */
    font-size: 1.5rem; /* フォントサイズを大きく */
    margin-top: 20px; /* 上の要素との間隔を調整 */
}

/* --- Hero Section Title Adjustments --- */
.main-title {
    top: -40px; /* さらに上に移動 */
}

.sub-catchphrase {
    top: -60px; /* さらに上に移動 */
}

/* --- Hero Section Event Date Adjustments --- */
.event-info-text {
    margin-top: -40px; /* さらに上に移動 */
}

/* --- CTA Section Note Adjustments --- */
.cta-note {
    top: -20px; /* さらに上に移動 */
}

/* --- Merits Section Padding Adjustment --- */
#merits {
    padding-bottom: 120px; /* 余白を調整 */
}

/* --- Event Details Margin Adjustment --- */
.event-details {
    margin-top: 0; /* 上のマージンをリセット */
}

/* --- Responsive Adjustments for Mobile --- */
@media (max-width: 768px) {
    :root { --header-height: 60px; }
    body {
        padding-top: var(--header-height);
        word-break: break-word; /* スマホでは単語の途中でも改行を許可して、はみ出しを防ぐ */
        line-break: normal; /* 改行ルールを通常に戻す */
    }

    .header .container { flex-direction: row; justify-content: space-between; align-items: center; padding: 10px; height: auto; }
    .header { height: var(--header-height); } /* 高さを固定 */
    
    .header nav {
        display: none; /* ハンバーガーメニューが有効な時は非表示 */
        flex-direction: column;
        position: fixed;
        top: var(--header-height);
        left: 0;
        width: 100%;
        background-color: var(--white-color);
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
        padding: 20px 0;
        z-index: 999;
        align-items: center;
    }

    .header nav.active {
        display: flex;
    }

    .header nav ul {
        flex-direction: column;
        gap: 15px;
        width: 100%;
        text-align: center;
    }

    .header nav ul li {
        width: 100%;
    }

    .header nav ul li a {
        display: block;
        padding: 10px 0;
        width: 100%;
    }

    .nav-cta {
        margin-top: 20px;
        padding: 10px 25px !important;
        font-size: 1rem;
        top: 0; /* 位置の調整をリセット */
    }

    .hamburger-menu {
        display: block; /* スマホで表示 */
    }

    .hero-title { font-size: 2.5rem; }
    .hero-subtitle { font-size: 1.2rem; }
    .hero-character { display: none; } /* モバイルでは非表示 */
    #hero { min-height: 60vh; }

    .section-title { font-size: 2.2rem; }
    .section-lead { margin: -30px auto 40px; }

    .service-grid { grid-template-columns: 1fr; }

    .service-content h3 {
        font-size: 1.0rem; /* スマホではフォントを小さくして1行に収める */
    }

    .service-content p {
        font-size: 0.75rem; /* 本文の文字をさらに小さく */
    }
    .features { grid-template-columns: 1fr; }
    .food-layout { grid-template-columns: 1fr; }
    .event-details { grid-template-columns: 1fr; }

    .schedule-table thead { display: none; }
    .schedule-table, .schedule-table tbody, .schedule-table tr, .schedule-table td {
        display: block;
        width: 100%;
    }
    .schedule-table tr {
        margin-bottom: 15px;
        border: 1px solid #e0e0e0;
        border-radius: 5px;
    }
    .schedule-table td {
        text-align: left;
        padding-left: 35%;
        position: relative;
        border: none;
        border-bottom: 1px solid #e0e0e0;
    }
    .schedule-table tr td:last-child { border-bottom: none; }
    .schedule-table td::before {
        content: attr(data-label);
        position: absolute;
        left: 15px;
        width: 30%;
        padding-right: 10px;
        white-space: nowrap;
        text-align: left;
        font-weight: bold;
        color: var(--primary-color);
    }

    .fixed-mobile-cta {
        position: fixed;
        bottom: 0; /* 下部に固定 */
        left: 0;
        width: 100%;
        padding: 15px 0; /* 上下のパディングを調整 */
        font-size: 1.2rem; /* フォントサイズ調整 */
        text-align: center;
        border-radius: 0; /* 角丸をなくす */
        z-index: 1000; /* 他の要素より手前に */
        display: block; /* スマホで表示 */
        top: auto; /* 上からの指定をリセット */
        right: auto; /* 右からの指定をリセット */
    }

    .main-title {
        font-size: 3.0rem; /* 少し小さく調整 */
        top: 10px; /* 少し下に配置 */
    }

    .sub-catchphrase {
        font-size: 1.5rem;
        top: 0;
    }

    .hero-content {
        padding-top: 20px;
    }

    .event-info-text {
        font-size: 1.1rem;
        white-space: normal;
        margin-top: 0;
        padding: 10px 15px;
    }

    .event-number {
        font-size: 1.2em;
        white-space: nowrap; /* 1行に収める */
    }

    .hero-cta {
        margin-top: 20px;
        top: 0;
    }

    .section-lead {
        margin-top: -20px;
    }

    #merits {
        padding-bottom: 80px;
    }

    .final-cta {
        padding: 15px 40px;
        font-size: 1.2rem;
        top: 0;
    }

    .cta-note {
        top: 0;
    }

    .section-lead {
        text-align: left;
    }

    .section-lead br {
        display: none; /* スマホで改行をなくす */
    }

    .section-lead {
        font-size: 0.8rem; /* 文字をさらに小さく */
        padding: 0 15px; /* 両端に余白を追加 */
    }

    .feature-item p {
        font-size: 0.8rem; /* 本文の文字を小さく */
    }
}

/* スマホだけに限定した文章改行改善 */
@media (max-width: 480px) {
  p {             /* pタグに適用 */
    line-break: strict;      /* 日本語の途中で変な改行を避ける */
    orphans: 2;              /* 段落の最後で孤立行を防ぐ */
    widows: 2;               /* 段落の最初で孤立行を防ぐ */
    word-break: break-word;  /* 単語途中で折り返す */
    overflow-wrap: break-word; /* 保険として折り返し対応 */
  }
}

/* ヘッダー内のCTAボタンの位置をリセット */
.header .nav-cta {
    top: 0;
    margin: 0;
}

/* スマホでのみ表示される改行 */
.br-sp {
    display: none; /* PCでは非表示 */
}

@media (max-width: 768px) {
    .br-sp {
        display: block; /* スマホでは表示 */
    }
}

/* PCでのみ表示される改行 */
.br-pc {
    display: none; /* スマホでは非表示 */
}

@media (min-width: 769px) { /* PCのブレークポイント */
    .br-pc {
        display: block; /* PCでは表示 */
    }

    .section-title {
        margin-bottom: 45px; /* 1.5cm (約15px) の余白を追加 */
    }

    .event-info-text {
        white-space: nowrap; /* 強制的に1行にする */
        font-size: 1.2rem; /* 1行に収まるように文字サイズを調整 */
        padding: 10px 80px; /* 左右のパディングをさらに増やして横長にする */
    }
}
