body {
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
    background: #f5f6f7;
}

.container {
    max-width: 700px;
    margin: 40px auto;
}

.card {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
}

input, textarea {
    width: 100%;
    padding: 8px;
    box-sizing: border-box;
}

button {
    padding: 10px 18px;
    border-radius: 6px;
    border: none;
    background: #4f46e5;
    color: #fff;
    font-size: 16px;
    cursor: pointer;
}

button:hover {
    opacity: 0.9;
}

/* カレンダー */
.calendar {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.calendar td {
    width: 14%;
    text-align: center;
    padding: 10px;
    cursor: pointer;
}

.calendar td.selected {
    background: #4f46e5;
    color: #fff;
    border-radius: 50%;
}

.answer-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.answer-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.choices {
    display: flex;
    gap: 8px;
}

/* radio は非表示 */
.choices input[type="radio"] {
    display: none;
}

/* ボタン化 */
.choice {
    width: 44px;
    height: 36px;
    border-radius: 6px;
    border: 1px solid #ccc;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 16px;
    background: #fff;
    user-select: none;
}

/* 選択状態 */
.choices input[type="radio"]:checked + .choice {
    color: #fff;
    border-color: transparent;
}

/* 種類別カラー */
.choice-○ {
    color: #16a34a;
}
.choices input[type="radio"]:checked + .choice-○ {
    background: #16a34a;
}

.choice-△ {
    color: #f59e0b;
}
.choices input[type="radio"]:checked + .choice-△ {
    background: #f59e0b;
}

.choice-× {
    color: #dc2626;
}
.choices input[type="radio"]:checked + .choice-× {
    background: #dc2626;
}

.submit-btn {
    margin-top: 20px;
    width: 100%;
}

.event-description {
    white-space: pre-wrap;
}

/* 横スクロール用 */
.schedule-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* 表 */
.schedule-table {
    border-collapse: collapse;
    width: max-content; /* ← 列数に応じて横に広がる */
    min-width: 100%;
}

/* セル共通 */
.schedule-table th,
.schedule-table td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: center;
    white-space: nowrap; /* ← 縦書き防止 */
}

/* 名前列を固定 */
.name-col {
    position: sticky;
    left: 0;
    background: #fff;
    z-index: 2;
    text-align: left;
    min-width: 100px;
    max-width: 160px;
    font-weight: 600;
}

/* ヘッダ行の名前セルを最前面に */
.schedule-table th.name-col {
    z-index: 3;
}

/* 回答セル */
.cell {
    min-width: 48px;
}

/* 日付表示 */
.date-label {
    display: flex;
    flex-direction: row;
    justify-content: center;
    gap: 4px;
}

.event-list {
    list-style: none;
    padding: 0;
}

.event-list li {
    padding: 12px 0;
    border-bottom: 1px solid #e5e7eb;
}

.event-list a {
    font-weight: 600;
    text-decoration: none;
    color: #111;
}

.event-list .meta {
    font-size: 12px;
    color: #6b7280;
}
