/* =========================
   基本スタイル
========================= */
html {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    font-size: 20px;
    scroll-behavior: smooth;
}

body {
    background: #fff6f2;
    color: #222;
    margin: 0;
    padding: 0;
    line-height: 1.8;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    font-size: 1.1rem;
    box-sizing: border-box;
}

/* =========================
   ヘッダー・ファーストビュー
========================= */
.main-header {
    background: #e9541b;
    color: #fff;
    border-radius: 0 0 24px 24px;
    box-shadow: 0 4px 16px rgba(233,84,27,0.10);
    padding-top: 0;
}

.header-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
}

.header-catch {
    flex: 1;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    width: 100%;
    font-size: 30px;
}

.header-catch h1, .header-catch p {
    margin: 0;
}

.header-catch h1 {
    font-size: 4vw;
}

.header-catch p {
    font-size: 1.5vw;
}

.header-catch div {
    margin-top: 3%;
    margin-bottom: 3%;
    margin-left: 5%;
    margin-right: 5%;
}

.header-btn-block {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.btn-detail {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: #e9541b;
    font-weight: bold;
    font-size: 1.2vw;
    border: 2px solid #e9541b;
    padding: 1em;
    border-radius: 24px;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
    text-align: center;
}

.btn-detail:hover, .btn-detail:focus {
    background: #e9541b;
    color: #fff;
    box-shadow: 0 4px 16px rgba(233,84,27,0.18);
    border-color: #b63c0a;
    transform: translateY(-2px) scale(1.04);
    outline: none;
}

.header-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.10);
    background: #fff;
}

/* =========================
   セクション
========================= */
section:not(.first-view) {
    max-width: 700px;
    margin: 40px auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(233,84,27,0.08);
    padding: 32px 24px;
    font-size: 1.2rem;
}
section:not(.first-view) h2 {
    color: #e9541b;
    font-size: 2rem;
    margin-top: 0;
    margin-bottom: 16px;
    border-left: 6px solid #e9541b;
    padding-left: 12px;
}

/* =========================
   参加者の声
========================= */
.voices {
    display: flex;
    flex-direction: column;
    gap: 24px;
}
.voice {
    background: #fff2ec;
    border-left: 4px solid #e9541b;
    padding: 16px 20px;
    border-radius: 8px;
}
.voice p {
    margin: 0 0 8px 0;
    font-size: 1.15rem;
}
.voice span {
    color: #b63c0a;
    font-size: 1.1rem;
}

/* =========================
   アニメーション
========================= */
.fade-in-up {
    opacity: 0;
    transform: translateY(40px);
    animation: fadeInUp 0.8s cubic-bezier(.23,1.02,.32,1) forwards;
}
@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: none;
    }
}

.zoom-in {
    opacity: 0;
    transform: scale(1.08);
    animation: zoomIn 1.2s cubic-bezier(.23,1.02,.32,1) 0.2s forwards;
}
@keyframes zoomIn {
    to {
        opacity: 1;
        transform: none;
    }
}

/* =========================
   スライダー
========================= */
.slider {
    position: relative;
    max-width: 500px;
    margin: 24px auto;
    overflow: hidden;
}
.slides {
    display: flex;
}
.slide {
    min-width: 100%;
    opacity: 1;
}
.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.7);
    border: none;
    font-size: 2rem;
    cursor: pointer;
    z-index: 2;
    padding: 0 12px;
    border-radius: 50%;
}
.slider-btn.prev {
    left: 10px;
}
.slider-btn.next {
    right: 10px;
}
.slider-indicators {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin: 12px 0 0 0;
    position: relative;
    z-index: 3;
}
.slider-indicator-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #e0a08a;
    border: 2px solid #e9541b;
    cursor: pointer;
    display: inline-block;
}
.slider-indicator-dot.active {
    background: #e9541b;
    border-color: #b63c0a;
}

/* =========================
   プルダウン（参加費エリア）モダンデザイン
========================= */
#fee-select-area {
    margin-top: 8px;
    margin-bottom: 8px;
    font-size: 1.1rem;
}
#fee-select-area label {
    margin-right: 8px;
    font-weight: bold;
}
#fee-select-area select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background: #fff;
    border: 2px solid #e9541b;
    border-radius: 8px;
    padding: 8px 36px 8px 16px;
    font-size: 1.1rem;
    color: #e9541b;
    font-weight: bold;
    outline: none;
    box-shadow: 0 2px 8px rgba(233,84,27,0.08);
    cursor: pointer;
    position: relative;
}
#fee-select-area select:focus {
    border-color: #b63c0a;
    box-shadow: 0 0 0 2px #e9541b33;
}
#fee-select-area {
    position: relative;
    display: inline-block;
}
#fee-select-area select {
    width: 160px;
}
#fee-select-area::after {
    content: '';
    position: absolute;
    top: 21%;
    right: 30px;
    width: 0;
    height: 0;
    pointer-events: none;
    border-left: 7px solid transparent;
    border-right: 7px solid transparent;
    border-top: 8px solid #e9541b;
}
#fee-select-area select::-ms-expand {
    display: none;
}

/* =========================
   申込ボタン中央寄せ
========================= */
.apply-btn-center {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 16px;
    margin-bottom: 8px;
}

/* =========================
   大聖院からのメッセージ
========================= */
.daishoin-image {
    width: 100%;
    border: 2px solid #e9541b;
    border-radius: 16px;
}

/* =========================
   運営紹介 学生リストカード
========================= */
.student-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px 24px;
    margin: 32px 0 0 0;
}

.student {
    background: #fff2ec;
    border: 2px solid #e9541b;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(233,84,27,0.10);
    padding: 24px 16px 16px 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.student:hover, .student:focus-within {
    box-shadow: 0 6px 24px rgba(233,84,27,0.18);
    transform: translateY(-2px) scale(1.03);
}
.student img {
    width: 96px;
    height: 96px;
    object-fit: cover;
    border-radius: 50%;
    margin-bottom: 12px;
    border: 2px solid #e9541b;
    background: #fff;
}
.student p {
    margin: 4px 0;
    text-align: center;
    font-size: 1.05rem;
    color: #b63c0a;
}
p.student-short-message {
    color: #1976d2;
}
/* =========================
   学生カード ポップアップモーダル
========================= */
.student-modal {
    position: fixed;
    z-index: 1000;
    left: 0; top: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.35);
    display: flex;
    align-items: center;
    justify-content: center;
}
.student-modal-content {
    background: #fff;
    border-radius: 16px;
    padding: 32px 24px 24px 24px;
    max-width: 90vw;
    width: 360px;
    box-shadow: 0 8px 32px rgba(233,84,27,0.18);
    position: relative;
    text-align: center;
    animation: fadeInUp 0.3s;
}
.student-modal-close {
    position: absolute;
    top: 12px;
    right: 18px;
    font-size: 2rem;
    color: #e9541b;
    cursor: pointer;
    font-weight: bold;
    background: none;
    border: none;
    outline: none;
    transition: color 0.2s;
}
.student-modal-close:hover, .student-modal-close:focus {
    color: #b63c0a;
}
#student-modal-title {
    margin-top: 0;
    margin-bottom: 12px;
    color: #e9541b;
    font-size: 1.3rem;
}
#student-modal-message {
    color: #222;
    font-size: 1.1rem;
    margin: 0;
    white-space: pre-line;
}
/* =========================
   ご協力
========================= */
.sponsor-list {
        display: grid;
        gap: 10px;
        grid-template-columns: 1fr 1fr 1fr;
        place-items: center;
    }
.sponsor-list img {
    width: 100%;
    padding-top: auto;
    padding-bottom: auto;
}

/* =========================
    お問い合わせ
========================= */
.contact-info {
    width: 100%;
    padding-left: 1em;
}

/* =========================
   ページトップへ戻るボタン
========================= */
#back-to-top {
    position: fixed;
    right: 24px;
    bottom: 32px;
    z-index: 1200;
    background: #e9541b;
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    font-size: 1.5rem;
    box-shadow: 0 4px 16px rgba(233,84,27,0.18);
    cursor: pointer;
    opacity: 0.85;
    outline: none;
}
#back-to-top:hover, #back-to-top:focus {
    background: #b63c0a;
    opacity: 1;
    transform: translateY(-2px) scale(1.08);
}

/* =========================
   レスポンシブ　スマートフォン
========================= */
@media (max-width: 600px) {
    html {
        font-size: 17px;
    }
    .header-inner {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        max-width: 100%;
        min-width: 0;
        box-sizing: border-box;
        height: auto;
    }
    .header-image {
        order: -1;
        justify-content: center;
        align-items: center;
        width: 100%;
        min-width: 0;
        min-height: 140px;
        height: auto;
        box-sizing: border-box;
    }
    .header-image img {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        min-height: 140px;
        max-height: 220px;
        border-radius: 16px;
        object-fit: cover;
        display: block;
        box-sizing: border-box;
    }
    .header-catch {
        text-align: center;
        width: 100%;
    }
    .header-catch h1 {
        font-size: 7vw;
        width: 100%;
    }
    .header-catch p {
        font-size: 3.9vw;
        width: 100%;
    }

    .btn-detail {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: #e9541b;
    font-weight: bold;
    font-size: 3vw;
    border: 2px solid #e9541b;
    padding: 1em;
    border-radius: 24px;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
    text-align: center;
    }
    
    .sponsor-list {
        display: grid;
        gap: 10px;
        grid-template-columns: 1fr 1fr;;
    }
    .sponsor-list img {
        width: 100%;
    }

    .contact-info {
    width: 100%;
    padding-left: 1em;
    font-size: 5vw;
    }

    section:not(.first-view) {
        padding: 20px 8px;
    }
    .voices {
        gap: 16px;
    }
    header {
        padding: 32px 0 0 0;
    }
    .header-firstview {
        padding-bottom: 16px;
    }
    .student-list {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .student {
        padding: 16px 8px 12px 8px;
    }
    .student img {
        width: 72px;
        height: 72px;
    }
    #back-to-top {
        right: 12px;
        bottom: 16px;
        width: 40px;
        height: 40px;
    }
    .contact-info {
        font-size: 0.85rem;
    }
}
