.timetable-page {
    --event-header-height: 28px;
}

.event-header {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: #fff;
    z-index: 1000;
    padding: 5px;
    border-bottom: 1px solid #ccc;
    text-align: left;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.timeline-header-avatar {
    flex: 0 0 auto;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    overflow: hidden;
    background: #e9ecef;
    border: 1px solid rgba(0, 0, 0, 0.08);
}

.timeline-header-avatar-link {
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
}

.timeline-header-avatar-link:hover,
.timeline-header-avatar-link:focus {
    text-decoration: none;
    opacity: 0.92;
}

.timeline-header-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.timeline-header-title {
    min-width: 0;
    flex: 1 1 auto;
}

.event-header h6 {
    margin: 0;
    padding-left: 0;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.event-image-carousel-wrap {
    max-width: 980px;
    margin: 56px auto 16px;
    padding: 0 12px;
}

.event-image-carousel {
    overflow: hidden;
    border-radius: 12px;
    background: #111;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.12);
}

.event-image-carousel-img-button {
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: zoom-in;
}

.event-image-carousel-img {
    width: 100%;
    height: 280px;
    object-fit: contain;
    background: #111;
}

@media (max-width: 768px) {
    .event-image-carousel-wrap {
        padding: 0 8px;
        margin-top: 8px;
        margin-bottom: 12px;
    }

    .event-image-carousel-img {
        height: 220px;
    }
}

@media (min-width: 769px) {
    .modal-dialog.event-info-modal-dialog {
        max-width: min(720px, calc(100vw - 2rem));
        margin: 1.75rem auto;
        transform: none;
    }

    .modal-dialog.event-info-modal-dialog .modal-content {
        max-width: 100%;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .modal-dialog.event-info-modal-dialog {
        max-width: calc(100vw - 1rem);
        margin: .5rem auto;
        transform: none;
    }
}

#eventBasicInfoModal.modal {
    z-index: 6000;
}

#eventBasicInfoModal.modal .modal-dialog {
    z-index: 6001;
}

.modal-backdrop {
    z-index: 5990 !important;
}

.event-image-lightbox-modal {
    z-index: 6100;
}

.event-image-lightbox-modal + .modal-backdrop,
.event-image-lightbox-modal ~ .modal-backdrop {
    z-index: 6090 !important;
}

.event-image-lightbox-dialog {
    width: min(98vw, 1600px);
    max-width: min(98vw, 1600px);
    margin: 0 auto;
    display: flex;
    align-items: center;
    min-height: calc(100vh - 1rem);
}

.event-image-lightbox-content {
    width: 100%;
    background: rgba(0, 0, 0, 0.96);
    border: 0;
    border-radius: 0;
    padding: 16px;
    max-height: calc(100vh - 1rem);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.event-image-lightbox-close {
    position: absolute;
    top: 8px;
    right: 16px;
    z-index: 2;
    color: #fff;
    opacity: 0.9;
    text-shadow: none;
}

.event-image-lightbox-close:hover,
.event-image-lightbox-close:focus {
    color: #fff;
    opacity: 1;
}

.event-image-lightbox-carousel {
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    width: 100%;
}

.event-image-lightbox-img {
    width: 100%;
    max-height: calc(100vh - 72px);
    object-fit: contain;
    background: transparent;
}

.btn-secondary {
    margin-right: 10px;
}

.timeline-container {
    position: relative;
    touch-action: pan-x pan-y;
    width: 100%;
}

.timeline-header {
    position: sticky;
    top: var(--event-header-height, 28px);
    background-color: #fff;
    z-index: 999;
    display: flex;
    width: 100%;
    font-size: 12px;
    overflow: hidden;
}

.time-axis-header {
    width: 40px;
    min-width: 40px;
    flex: 0 0 40px;
}

.venues-header {
    position: relative;
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    align-items: stretch;
    padding: 3px 0;
    text-align: center;
    font-size: 12px;
    overflow-x: auto;
    overflow-y: hidden;
    box-sizing: border-box;
    scrollbar-width: none;
}

.venues-header::-webkit-scrollbar,
.venues::-webkit-scrollbar {
    display: none;
}

.timeline-body {
    display: flex;
    position: relative;
    top: 40px;
    width: 100%;
}

.venue-column-header {
    width: 220px;
    min-width: 220px;
    flex: 0 0 220px;
    padding: 3px;
    border-right: 1px solid #ccc;
    text-align: center;
    background-color: #fff;
    box-sizing: border-box;
}

.venue-column-header h5 {
    margin: 0;
    font-size: 14px;
    line-height: 1.25;
    word-break: break-word;
}


.venues {
    position: relative;
    display: flex;
    top: 0;
    flex: 1 1 auto;
    min-width: 0;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
}

.time-axis {
    position: relative;
    left: 0;
    top: 0;
    width: 20px;
    min-width: 20px;
    flex: 0 0 20px;
    z-index: 10;
}

.time-header {
    height: auto;
}

.time-label {
    height: 160px;
    border-bottom: 2px solid #ccc;
    border-top: 2px solid #ccc;
    position: relative;
}

.time-label-text {
    position: absolute;
    z-index: 20;
    left: 0;
}

.gray-line {
    position: absolute;
    left: 0;
    width: 100%;
    height: 2px;
    z-index: 9;
}

#current-time-line {
    position: absolute;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: red;
    z-index: 999;
}

#current-time-text {
    position: absolute;
    top: -10px;
    left: 5px;
    padding: 2px 5px;
    background: rgba(255, 255, 255, 0.8);
    font-size: 20px;
}

.venue-column {
    position: relative;
    margin-left: 0;
    min-width: 200px;
    border-left: 1px solid rgba(0, 0, 0, 0.12);
    border-right: 1px solid rgba(0, 0, 0, 0.12);
    box-sizing: border-box;
    background-clip: padding-box;
}

.venue-timetables {
    position: relative;
    min-height: 100%;
}

.schedule-block {
    position: absolute;
    left: 0;
    width: calc(100% - 10px);
    margin-bottom: 5px;
    z-index: 100;
    box-sizing: border-box;
    overflow: hidden;
}

.schedule-block.not-selected {
    opacity: 0.4;
}

.schedule-block p {
    margin: 0;
    padding-left: 5px;
}

.schedule-time-range {
    font-size: 0.8rem;
    line-height: 1.2;
}

.schedule-performer-list {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.schedule-performer-pill {
    font-size: 0.72rem;
    line-height: 1.15;
    padding: 0.28rem 0.45rem;
}

.schedule-performer-pill[class*="favorite-color-"] {
    background-color: var(--favorite-accent) !important;
    color: var(--favorite-accent-text) !important;
    border-color: var(--favorite-accent) !important;
}

.schedule-performer-summary {
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.55);
    color: #374151;
}

.favorite-icons {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    height: 16px;
}

.favorite-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.favorite-star {
    display: inline-block;
    font-size: 11px;
    line-height: 1;
}

.favorite-icon {
    font-size: 16px;
    color: transparent;
    transition: color 0.3s;
}

.schedule-block.selected .favorite-icon {
    color: red;
}

.favorite-count {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 1;
    color: #fff;
    text-shadow: 0 0 1px rgba(0, 0, 0, 0.35);
}

.favorite-count i {
    font-size: 0.85rem;
}

.favorite-count.selected {
    color: #ffefef;
}

.gray-highlight {
    background-color: rgba(11, 11, 11, 1);
    position: absolute;
    left: 0;
    width: 100%;
    z-index: 0;
}

.floating-buttons-left {
    position: fixed;
    bottom: 80px;
    left: 10px;
    display: flex;
    gap: 10px;
    z-index: 2001;
}

.floating-buttons-center {
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 1001;
}

.floating-buttons-right {
    position: fixed;
    bottom: 80px;
    right: 10px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 2001;
}

.filter-btn, .share-btn, .export-btn, .comment-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background-color: rgba(200, 200, 200, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.3s;
}

.filter-btn:hover, .share-btn:hover, .export-btn:hover, .comment-btn:hover {
    background-color: rgba(0, 0, 0, 0.5);
    transform: scale(1.1);
    color: white;
}

.filter-btn.active, .share-btn.active, .export-btn.active, .comment-btn.active {
    background-color: rgba(0, 0, 0, 0.3);
}

.favolite-btn {
    color: red;
}

.favolite-btn:hover {
    color: red;
}

.modal {
    display: none;
    position: fixed;
    z-index: 1050;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    outline: 0;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-dialog {
    position: relative;
    width: auto;
    max-width: 600px;  /* 最大幅を小さく */
    margin: 10px;
    pointer-events: none;
}

.modal-content {
    position: relative;
    display: flex;
    max-width: 600px;  /* 最大幅を小さく */
    margin: auto;
    background-color: #fff;
    background-clip: padding-box;
    border: 1px solid rgba(0, 0, 0, 0.2);
    border-radius: 0.3rem;
    outline: 0;
    pointer-events: auto;
}

.comment {
    border-bottom: 1px solid #ddd;
    padding: 5px;
}

.like-btn, .reply-btn {
    margin-right: 10px;
    cursor: pointer;
    font-size: 12px;
    background: none;
    border: none;
    color: #007bff;
    text-decoration: underline;
}

.comment p {
    margin: 5px 0;
}



.timeline-container {
    position: relative;
    touch-action: pan-x pan-y; /* スクロール方向を自由に設定 */
<!--    overflow: auto;-->
    width: 100%;
}

#current-time-line2 {
    position: fixed; /* 要素を画面に固定 */
    left: 0; /* 左端に配置 */
    width: 100vw; /* 画面の幅いっぱいに設定 */
    height: 2px; /* 高さを設定 */
    background-color: red; /* 線の色 */
    z-index: 999; /* 他の要素より前面に表示 */
}

.time-line {
    position: absolute; /* 要素を画面に固定 */
    left: 0; /* 左端に配置 */
    width: 100%; /* 画面の幅いっぱいに設定 */
    height: 2px; /* 高さを設定 */
    z-index: 999; /* 他の要素より前面に表示 */
}


#current-time-text {
    position: absolute;
    top: -10px;
    left: 5px;
    padding: 2px 5px;
    background: rgba(255, 255, 255, 0.8);
    font-size: 20px;
}


.time-axis {
    left: 0; /* 左端に固定 */
    top: 0; /* 上端に固定 */
    width: 20px; /* 固定要素の幅を設定 */
    z-index: 10; /* スクロール中でも上に表示する */
}

.time-header {
    height: auto;
}



.time-label-text {
    position: absolute;
    z-index: 20; /* テキスト自体をさらに前面に配置 */
}

.gray-highlight {
    background-color: rgba(11, 11, 11, 1); /* グレーにする背景色 */
    position: absolute;
    left: 0;
    width: 100%;
    z-index: 0; /* 帯を背面に配置 */
}

.event-bookmark-toggle {
    color: #2f3a4a;
}

.bookmark-feedback-container {
    position: fixed;
    top: 72px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3002;
    pointer-events: none;
    width: min(92vw, 420px);
}

.bookmark-feedback-toast {
    pointer-events: auto;
    margin-bottom: 0;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.18s ease, transform 0.18s ease;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
}

.bookmark-feedback-toast.show {
    opacity: 1;
    transform: translateY(0);
}
