/* ==========================================================================
   HERO'S FESTIVAL - 大学祭HP アメコミ風スタイル
   Main colors: Orange #f1a624 / Vivid Red #e43110
   ========================================================================== */

:root {
  --comic-orange: #f1a624;
  --comic-red: #e43110;
  --comic-black: #1a1611;
  --comic-cream: #ffff99;
  --comic-navy: #1c2340;
  
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Noto Sans JP', sans-serif;
  background-color: var(--comic-cream);
  color: var(--comic-black);
  overflow-x: hidden;
}

.font-comic {
  font-family: 'RocknRoll One', 'Noto Sans JP', sans-serif;
}

.font-impact {
  font-family: 'Bangers', 'RocknRoll One', sans-serif;
  letter-spacing: 0.03em;
}

/* --- Halftone dot texture backgrounds --- */
.halftone-bg {
  background-image: radial-gradient(circle, rgba(26, 22, 17, 0.18) 1.6px, transparent 1.8px);
  background-size: 14px 14px;
}

.halftone-orange {
  background-image: radial-gradient(circle, rgba(228, 49, 16, 0.35) 1.8px, transparent 2px);
  background-size: 16px 16px;
}

.halftone-white {
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.5) 1.8px, transparent 2px);
  background-size: 16px 16px;
}

/* --- Comic borders & panel look --- */
.comic-border {
  border: 4px solid var(--comic-black);
  box-shadow: 6px 6px 0 var(--comic-black);
}

.comic-border-sm {
  border: 3px solid var(--comic-black);
  box-shadow: 4px 4px 0 var(--comic-black);
}

.comic-panel {
  border: 4px solid var(--comic-black);
  border-radius: 4px;
  box-shadow: 8px 8px 0 var(--comic-black);
  background: #fff;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.comic-panel:hover {
  transform: translate(-3px, -3px);
  box-shadow: 11px 11px 0 var(--comic-black);
}

/* --- Comic button --- */
.btn-comic {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: 'RocknRoll One', sans-serif;
  font-weight: 700;
  border: 3px solid var(--comic-black);
  border-radius: 999px;
  box-shadow: 5px 5px 0 var(--comic-black);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  white-space: nowrap;
}

.btn-comic:hover {
  transform: translate(-2px, -2px);
  box-shadow: 7px 7px 0 var(--comic-black);
}

.btn-comic:active {
  transform: translate(1px, 1px);
  box-shadow: 2px 2px 0 var(--comic-black);
}

/* --- Burst / star shape --- */
.burst-shape {
  clip-path: polygon(50% 0%, 61% 18%, 82% 8%, 82% 30%, 100% 35%, 88% 50%,
    100% 65%, 82% 70%, 82% 92%, 61% 82%, 50% 100%, 39% 82%,
    18% 92%, 18% 70%, 0% 65%, 12% 50%, 0% 35%, 18% 30%, 18% 8%, 39% 18%);
}

/* --- Speech bubble --- */
.speech-bubble {
  position: relative;
  background: #fff;
  border: 4px solid var(--comic-black);
  border-radius: 1.5rem;
}

.speech-bubble::after {
  content: '';
  position: absolute;
  left: 42px;
  bottom: -26px;
  width: 0;
  height: 0;
  border: 16px solid transparent;
  border-top-color: var(--comic-black);
  border-bottom: 0;
}

.speech-bubble::before {
  content: '';
  position: absolute;
  left: 45px;
  bottom: -19px;
  width: 0;
  height: 0;
  border: 13px solid transparent;
  border-top-color: #fff;
  border-bottom: 0;
  z-index: 1;
}

/* --- Section title with comic tag --- */
.section-tag {
  display: inline-block;
  font-family: 'Bangers', 'RocknRoll One', sans-serif;
  transform: rotate(-3deg);
  border: 3px solid var(--comic-black);
  box-shadow: 4px 4px 0 var(--comic-black);
}

/* --- Nav link underline pop --- */
.nav-link {
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0%;
  height: 3px;
  background: var(--comic-red);
  transition: width 0.25s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* --- Tab buttons for schedule/day switch --- */
.day-tab {
  font-family: 'RocknRoll One', sans-serif;
  border: 3px solid var(--comic-black);
  transition: all 0.2s ease;
}

.day-tab.active {
  background: var(--comic-red);
  color: #fff;
  box-shadow: 4px 4px 0 var(--comic-black);
  transform: translate(-2px, -2px);
}

/* --- Timeline --- */
.timeline-item {
  position: relative;
  padding-left: 2.25rem;
  border-left: 4px dashed var(--comic-black);
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -11px;
  top: 4px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--comic-orange);
  border: 3px solid var(--comic-black);
}

/* --- スケジュールを覆う白い長方形 --- */
.schedule-white-box {
  position: relative;
  background-color: #ffffff;
  width: 100%;
  border-radius: 24px; /* 角の丸み */
  padding: 24px; /* スマホなどの小さな画面用の余白 */
  box-sizing: border-box;
}

.schedule-cover {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #faa639;
  border-radius: 24px; /* 親要素の丸みに合わせる */
  z-index: 10; /* テキストより前面に配置して文字を見えなくする */
}

/* --- Badge --- */
.badge-comic {
  font-family: 'RocknRoll One', sans-serif;
  font-size: 0.75rem;
  border: 2px solid var(--comic-black);
  border-radius: 999px;
  padding: 0.15rem 0.75rem;
  display: inline-block;
}

/* --- Scroll reveal animation --- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

/* --- Pow decoration pulse --- */
@keyframes pop-pulse {
  0%, 100% { transform: scale(1) rotate(-4deg); }
  50% { transform: scale(1.08) rotate(-4deg); }
}

.pop-pulse {
  animation: pop-pulse 2.4s ease-in-out infinite;
}

@keyframes float-y {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.float-y {
  animation: float-y 3.5s ease-in-out infinite;
}

/* --- Comic dotted divider --- */
.dotted-divider {
  height: 6px;
  background-image: repeating-linear-gradient(90deg, var(--comic-black) 0, var(--comic-black) 10px, transparent 10px, transparent 20px);
}

/* --- Zigzag divider --- */
.zigzag-top {
  height: 24px;
  background: linear-gradient(135deg, var(--comic-cream) 25%, transparent 25%) -12px 0,
    linear-gradient(225deg, var(--comic-cream) 25%, transparent 25%) -12px 0;
  background-size: 24px 24px;
  background-color: var(--comic-black);
}

/* --- Custom scrollbar --- */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--comic-cream);
}

::-webkit-scrollbar-thumb {
  background: var(--comic-red);
  border: 2px solid var(--comic-black);
}

/* --- Loading spinner --- */
.comic-spinner {
  width: 44px;
  height: 44px;
  border: 5px solid var(--comic-black);
  border-top-color: var(--comic-red);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* --- Mobile menu --- */
#mobile-menu {
  transition: transform 0.3s ease, opacity 0.3s ease;
}

/* --- Sponsor tier heading --- */
.tier-platinum { color: var(--comic-red); }
.tier-gold { color: var(--comic-orange); }

/* Responsive tweak for speech bubble */
@media (max-width: 640px) {
  .comic-panel:hover {
    transform: none;
    box-shadow: 8px 8px 0 var(--comic-black);
  }
}

/* --- Main event page-flip book --- */
#main-events-section .main-event-wrap {
  display: grid;
  place-items: center;
  gap: 8px;
  color: var(--comic-cream);
}

#main-events-section .main-event-book-shell {
  width: min(100%, 743px);
  aspect-ratio: 1220 / 920;
  max-width: 100%;
}

#main-event-book {
  width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  background: #fff;
  box-shadow: 11px 11px 0 var(--comic-orange);
  touch-action: none;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
  filter: saturate(1.02) contrast(0.985);
}

#main-event-book:active {
  cursor: grabbing;
}

#main-event-book .main-event-page {
  box-sizing: border-box;
  overflow: hidden;
  background: #fff;
}

#main-event-book .main-event-info {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(10px, 4vw, 37px);
  color: #292929;
  font-family: 'RocknRoll One', sans-serif;
}

#main-event-book .main-event-ornament {
  position: absolute;
  right: 3%;
  bottom: 4%;
  z-index: 2;
  width: 34%;
  height: auto;
  transform: rotate(12deg);
  transform-origin: center;
  pointer-events: none;
}

#main-event-book .main-event-label {
  color: #a46f45;
  font-size: clamp(8px, 1.75vw, 13px);
  font-weight: 700;
  letter-spacing: 0.18em;
}

#main-event-book .main-event-info h3 {
  margin: clamp(5px, 1.6vw, 12px) 0 clamp(9px, 3.7vw, 28px);
  font-size: clamp(16px, 4vw, 30px);
  line-height: 1.2;
}

#main-event-book .main-event-info dl {
  display: grid;
  grid-template-columns: 3em minmax(0, 1fr);
  gap: clamp(4px, 1.6vw, 12px) clamp(5px, 2.1vw, 16px);
  margin: 0 0 clamp(9px, 3.7vw, 28px);
  font-size: clamp(8px, 1.9vw, 14px);
  line-height: 1.45;
}

#main-event-book .main-event-info dt {
  font-weight: 700;
}

#main-event-book .main-event-info dd {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
}

#main-event-book .main-event-info p {
  margin: 0;
  font-size: clamp(8px, 1.9vw, 14px);
  line-height: 1.6;
  overflow-wrap: anywhere;
}

/* メインイベントの画像に関する指定 */
#main-event-book .main-event-image .schedule-white-box {
  width: 100%;
  height: 100%;
}
#main-event-book .main-event-image  {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: #fff;
}
#main-event-book .main-event-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

#main-event-book::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.06;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)' opacity='.35'/%3E%3C/svg%3E");
}

#main-events-section .main-event-guide {
  margin-top: 8px;
  color: var(--comic-cream);
  font-size: 0.875rem;
  text-align: center;
}

#main-events-section .main-event-controls {
  display: flex;
  gap: 12px;
  margin-top: -6px;
}

#main-events-section .main-event-controls button {
  width: 100px;
  height: 100px;
  border: 0;
  padding: 0 0 10px;
  background-color: transparent;
  background-image: url('../assets/ornament/attension.svg');
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
  color: var(--comic-black);
  cursor: pointer;
  font-family: 'RocknRoll One', sans-serif;
  font-size: 22px;
}

#main-events-section .main-event-controls button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

@media (max-width: 600px) {
  #main-events-section .main-event-controls {
    gap: 8px;
  }

  #main-events-section .main-event-controls button {
    width: 58px;
    height: 48px;
    padding: 0;
    font-size: 14px;
  }
}

/* お問い合わせフォーム */
/* セクション全体のスタイル */
#contact-section {
  padding: 80px 0 100px 0;    /* 下余白を増やす */
  overflow: hidden;
  margin-bottom: 0;
}

/* セクションタイトルのスタイル */
#contact-section h2 {
    font-size: 3rem;
    text-align: center;
    color: #333;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 4rem;
    position: relative;
}

#contact-section h2::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 350px;
    height: 4px;
    /* background-color: var(--comic-red); */
}

/* フォーム全体のコンテナ */
#contact-section form {
    max-width: 800px;
    width: 90%;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.95);
    padding: 60px 40px;
    border-radius: 12px;
    border: 4px solid var(--comic-black);
    box-shadow: 8px 8px 0 var(--comic-black);
}

/* フォーム項目全体のレイアウト */
#contact-section dl {
    margin-bottom: 40px;
}

/* ラベル部分のスタイル */
#contact-section dt {
    font-family: 'RocknRoll One', 'Noto Sans JP', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    color: var(--comic-black);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
    display: block;
}

/* 入力欄部分のレイアウト */
#contact-section dd {
    margin-bottom: 32px;
}

/* 入力フィールドとテキストエリアの共通スタイル */
#contact-section dd input,
#contact-section dd textarea {
    width: 100%;
    border: 2px solid #e0e0e0;
    padding: 16px 20px;
    background-color: #fff;
    border-radius: 8px;
    font-size: 1rem;
    font-family: 'Noto Sans JP', sans-serif;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

/* 入力フィールドのフォーカス時のスタイル */
#contact-section dd input:focus,
#contact-section dd textarea:focus {
    outline: none;
    border-color: var(--comic-red);
    box-shadow: 4px 4px 0 var(--comic-orange);
    transform: translateY(-2px);
}

/* テキストエリアの高さ設定 */
#contact-section dd textarea {
    height: 150px;
    resize: vertical;
}

/* 送信ボタンのコンテナ */
#contact-section .button {
    text-align: center;
    margin-top: 40px;
}

/* 送信ボタンのスタイル */
#contact-section .button input {
    width: 240px;
    background: var(--comic-red);
    color: #fff;
    padding: 18px 0;
    border: 3px solid var(--comic-black);
    border-radius: 50px;
    font-family: 'RocknRoll One', 'Noto Sans JP', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 5px 5px 0 var(--comic-black);
}

/* 送信ボタンのホバー効果 */
#contact-section .button input:hover {
    background: #c9270b;
    transform: translateY(-3px);
    box-shadow: 7px 7px 0 var(--comic-black);
}

/* 送信ボタンのアクティブ効果 */
#contact-section .button input:active {
    transform: translateY(-1px);
    box-shadow: 2px 2px 0 var(--comic-black);
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    #contact-section form {
        padding: 40px 24px;
        width: 95%;
    }

    #contact-section h2 {
        font-size: 2.5rem;
    }

    #contact-section .button input {
        width: 200px;
        padding: 16px 0;
    }
}
/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.modal-overlay.visible {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    max-width: 800px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    transform: scale(0.9);
    transition: transform 0.3s;
}

.modal-overlay.visible .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 2.5rem;
    cursor: pointer;
    
}
.modal-close:active {
  transform: scale(0.85); /* 少し縮む */
}
