.rs-calendar-wrap,
.rs-reservation-wrap {
	max-width: 960px;
	margin: 0 auto;
	padding: 20px 16px;
	box-sizing: border-box;
}

.rs-calendar-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 16px;
}

.rs-calendar-header strong {
	font-size: 1.2rem;
	font-weight: 700;
	color: #222;
}

.rs-calendar-header button,
#rs-submit,
.rs-slot-btn {
	appearance: none;
	-webkit-appearance: none;
	border: 1px solid #d8d8d8;
	background: #fff;
	color: #222;
	border-radius: 10px;
	cursor: pointer;
	transition: background-color 0.2s ease, border-color 0.2s ease, opacity 0.2s ease;
}

.rs-calendar-header button {
	padding: 10px 16px;
	font-size: 0.95rem;
	line-height: 1.4;
}

.rs-calendar-header button:hover,
#rs-submit:hover,
.rs-slot-btn:hover {
	background: #f7f7f7;
	border-color: #bfbfbf;
}

.rs-calendar-legend {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 14px;
	font-size: 0.9rem;
	color: #555;
	margin-bottom: 14px;
}

#rs-calendar-table {
	width: 100%;
	border-collapse: collapse;
	table-layout: fixed;
	background: #fff;
	border: 1px solid #ddd;
}

#rs-calendar-table th,
#rs-calendar-table td {
	border: 1px solid #ddd;
	text-align: left;
	vertical-align: top;
	box-sizing: border-box;
}

#rs-calendar-table th {
	background: #faf7f2;
	font-weight: 700;
	font-size: 0.95rem;
	text-align: center;
	padding: 10px 6px;
}

#rs-calendar-table td {
	height: 110px;
	padding: 8px;
	font-size: 0.95rem;
	position: relative;
}

.rs-day-cell {
	transition: background-color 0.2s ease, transform 0.15s ease;
}

.rs-day-cell[data-date] {
	cursor: pointer;
}

.rs-day-cell[data-date]:hover {
	background: #fff8ee !important;
}

.rs-day-cell > div:first-child {
	font-weight: 700;
	font-size: 1rem;
	margin-bottom: 6px;
}

.rs-day-cell > div:last-child {
	font-size: 0.78rem;
	line-height: 1.4;
	word-break: break-word;
}

.rs-field {
	margin-bottom: 18px;
}

.rs-field label {
	display: block;
	margin-bottom: 8px;
	font-size: 1rem;
	font-weight: 700;
	color: #222;
}

#rs-selected-date {
	background: #fafafa;
	border-radius: 10px;
	padding: 14px 16px;
	font-size: 1rem;
	line-height: 1.5;
}

#rs-slots {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}

.rs-slot-btn {
	padding: 10px 16px;
	font-size: 0.98rem;
	line-height: 1.4;
	min-width: 92px;
	text-align: center;
}

.rs-slot-btn[disabled] {
	background: #f1f1f1;
	color: #999;
	border-color: #ddd;
	cursor: not-allowed;
	opacity: 1;
}

.rs-slot-btn[style*="font-weight:bold"] {
	background: #f4ecde;
	border-color: #c9a86a;
}

#rs-reservation-form {
	margin-top: 20px;
	padding: 18px;
	border: 1px solid #e3e3e3;
	border-radius: 14px;
	background: #fff;
	box-sizing: border-box;
}

#rs-reservation-form input,
#rs-reservation-form select {
	width: 100%;
	max-width: 100%;
	padding: 12px 14px;
	font-size: 1rem;
	line-height: 1.5;
	border: 1px solid #ccc;
	border-radius: 10px;
	background: #fff;
	box-sizing: border-box;
}

#rs-reservation-form input:focus,
#rs-reservation-form select:focus {
	outline: none;
	border-color: #b78d49;
	box-shadow: 0 0 0 3px rgba(183, 141, 73, 0.12);
}

#rs-submit {
	display: inline-block;
	min-width: 180px;
	padding: 12px 22px;
	font-size: 1rem;
	font-weight: 700;
	background: #f3b562;
	border-color: #e2a14b;
	color: #222;
}

#rs-submit:hover {
	background: #efab4d;
	border-color: #da9338;
}

#rs-message > div {
	border-radius: 10px;
	padding: 12px 14px !important;
	font-size: 0.95rem;
	line-height: 1.6;
	background: #fff;
	box-sizing: border-box;
}

/* タブレット */
@media (max-width: 900px) {
	.rs-calendar-wrap,
	.rs-reservation-wrap {
		padding: 18px 14px;
	}

	#rs-calendar-table td {
		height: 95px;
		padding: 6px;
	}

	.rs-day-cell > div:first-child {
		font-size: 0.95rem;
	}

	.rs-day-cell > div:last-child {
		font-size: 0.72rem;
	}
}

/* スマホ */
@media (max-width: 640px) {
	.rs-calendar-header {
		gap: 10px;
	}

	.rs-calendar-header strong {
		font-size: 1rem;
		text-align: center;
		flex: 1;
	}

	.rs-calendar-header button {
		padding: 9px 12px;
		font-size: 0.9rem;
	}

	.rs-calendar-legend {
		font-size: 0.82rem;
		gap: 6px 10px;
	}

	#rs-calendar-table th {
		font-size: 0.78rem;
		padding: 8px 4px;
	}

	#rs-calendar-table td {
		height: 78px;
		padding: 4px;
	}

	.rs-day-cell > div:first-child {
		font-size: 0.88rem;
		margin-bottom: 4px;
	}

	.rs-day-cell > div:last-child {
		font-size: 0.66rem;
		line-height: 1.25;
	}

	#rs-slots {
		gap: 8px;
	}

	.rs-slot-btn {
		flex: 1 1 calc(50% - 8px);
		min-width: 0;
		padding: 10px 8px;
		font-size: 0.92rem;
	}

	#rs-reservation-form {
		padding: 14px;
		border-radius: 12px;
	}

	#rs-reservation-form input,
	#rs-reservation-form select {
		font-size: 16px;
	}

	#rs-submit {
		width: 100%;
		min-width: 0;
	}
}

/* 極小スマホ */
@media (max-width: 420px) {
	.rs-calendar-wrap,
	.rs-reservation-wrap {
		padding: 14px 10px;
	}

	#rs-calendar-table td {
		height: 70px;
	}

	.rs-day-cell > div:first-child {
		font-size: 0.82rem;
	}

	.rs-day-cell > div:last-child {
		font-size: 0.6rem;
	}

	.rs-slot-btn {
		flex: 1 1 100%;
	}
}

/* ===== フォーム整形（2カラム） ===== */

#rs-reservation-form .rs-field {
	display: grid;
	grid-template-columns: 180px 1fr;
	align-items: center;
	gap: 12px;
	margin-bottom: 16px;
}

/* ラベル */
#rs-reservation-form label {
	margin-bottom: 0;
	font-weight: 600;
	font-size: 0.95rem;
}

/* 入力欄 */
#rs-reservation-form input,
#rs-reservation-form select {
	width: 100%;
}

/* 日付表示は別扱い */
#rs-selected-date {
	grid-column: span 2;
}

/* 時間帯エリアも横いっぱい */
#rs-slots {
	grid-column: span 2;
}

/* ボタンは中央寄せ */
#rs-submit {
	grid-column: span 2;
	justify-self: center;
}

/* ===== スマホ対応 ===== */
@media (max-width: 640px) {
	#rs-reservation-form .rs-field {
		grid-template-columns: 1fr;
		align-items: flex-start;
	}

	#rs-submit {
		width: 100%;
	}
}


#rs-cancel-submit {
	display: inline-block;
	min-width: 220px;
	padding: 12px 22px;
	font-size: 1rem;
	font-weight: 700;
	background: #d9534f;
	border: 1px solid #c94743;
	color: #fff;
	border-radius: 10px;
	cursor: pointer;
	transition: background-color 0.2s ease, opacity 0.2s ease;
}

#rs-cancel-submit:hover {
	background: #c94440;
}

#rs-cancel-submit:disabled {
	opacity: 0.7;
	cursor: not-allowed;
}

.rs-cancel-confirm p {
	margin: 0 0 10px;
	line-height: 1.8;
	word-break: break-word;
}

