/**
 * Tier 2 Calendar Styles — T12-FE
 *
 * Styles the custom jQuery calendar booking widget on /calendar-booking/.
 * Layout: left info panel + right calendar/time-slot grid.
 */

/* =====================================================================
 * Wrapper — two-column layout
 * =================================================================== */

.tier2-calendar-wrapper {
    display: flex;
    gap: 0;
    margin: 100px auto !important;
    background: #fff;
    box-shadow: 0 4px 20px rgb(0 0 0 / 4%);
}

.tier2-calendar-wrapper a {
    color: black;
    font-weight: bold;
    text-decoration: blink;
    font-size: 16px;
}

/* =====================================================================
 * Left panel — call info
 * =================================================================== */

.calendar-info {
    padding: 40px;
    flex: 0 0 500px;
    background: #F2F4F7;
}

.calendar-info .icon {
    width: 48px;
    height: 48px;
    background: #E6EAEE;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 25px;
}

.calendar-info h2 {
    padding: 30px 0 8px;
    font-size: 24px;
    font-weight: bold;
    color: #032644;
    margin: 0;
}

.calendar-info .duration {
    margin: 0 0 20px !important;
    color: #666;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.calendar-info .description {
	color: #555;
	font-size: 14px;
	line-height: 1.6;
}

/* =====================================================================
 * Calendar grid
 * =================================================================== */

#tier2-calendar {
    padding: 40px;
    flex: 1;
    background: white;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.calendar-header h2 {
    font-size: 20px;
    font-weight: bold;
    color: #032644;
    margin: 0;
    padding: 0;
}

/* Month navigation */
.month-nav {
    display: flex;
    align-items: center;
    gap: 26px;
}

.month-nav button {
    font-size: 18px !important;
    color: #191C1E;
    border: unset;
    background: transparent;
    cursor: pointer;
    color: #333;
    transition: all 0.2s;
    padding: 0;
    height: auto;
}

.month-nav button:hover:not([disabled]) {
	background: #f5f5f5;
}

.month-nav button[disabled] {
	opacity: 0.3;
	cursor: not-allowed;
}

.current-month {
    letter-spacing: 1.4px;
    font-size: 14px;
    font-weight: 700;
    color: #191C1E;
}

/* Grid container */
.calendar-grid {
	overflow: hidden;
}

/* Day-of-week headers (MON TUE …) */
.day-headers {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
}

.day-header {
    padding: 10px;
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    color: #43474D;
}

/* Day cells */
.days {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
}

.day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: #191C1E;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    border: 1px solid transparent;
}

.day.empty {
	cursor: default;
}

.day.past, .day.unavailable {
    color: #C3C6CE;
    cursor: not-allowed;
}

.day.available:hover {
    background: #032644;
    color: white;
}

.day.selected {
	background: #1a2b3c;
	color: #fff;
	font-weight: 600;
}

/* =====================================================================
 * Time slots
 * =================================================================== */

.time-slots-container {
	margin-top: 24px;
}

.time-slots-header {
	font-size: 12px;
	font-weight: 500;
	color: #666;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin-bottom: 16px;
}

.selected-date-display {
	color: #1a2b3c;
}

.slots-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.time-slot {
    padding: 12px 15px;
    border: 1px solid #EDEEF0;
    border-radius: 0;
    text-align: center;
    font-size: 14px;
    color: #032644;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
    font-weight: 500;
}

.time-slot:hover:not(.booked) {
    border-color: #1a2b3c;
    background: #F2F4F6;
}

.time-slot.booked {
	background: #f5f5f5;
	color: #999;
	cursor: not-allowed;
	text-decoration: line-through;
}

.time-slot.selected {
    border-color: #1a2b3c;
    background: #F2F4F6;
    color: #032644;
}

.selected-badge {
	position: absolute;
	top: -8px;
	right: -8px;
	background: #1a2b3c;
	color: #fff;
	font-size: 9px;
	padding: 2px 6px;
	border-radius: 3px;
	font-weight: 600;
}

/* =====================================================================
 * Confirm button
 * =================================================================== */

.confirm-section {
	margin-top: 24px;
	text-align: right;
}

.confirm-btn {
    color: #fff;
    border: none;
    padding: 16px 40px;
    font-size: 18px;
    font-weight: bold;
    border-radius: 0;
    transition: all 0.2s;
    background: #17517e;
}

.confirm-btn:hover {
    background: #17517e;
}

.confirm-btn:disabled {
	background: #ccc;
	cursor: not-allowed;
}

/* =====================================================================
 * Loading / error / empty states
 * =================================================================== */

.loading,
.error,
.no-slots {
	padding: 40px;
	text-align: center;
	color: #666;
}

.error {
	color: #dc3545;
}

/* =====================================================================
 * Responsive — stack on mobile
 * =================================================================== */

@media (max-width: 768px) {
	.tier2-calendar-wrapper {
		flex-direction: column;
	}

	.calendar-info {
		flex: none;
	}

	.slots-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	.calendar-header {
		flex-direction: column;
		gap: 12px;
	}
}


@media screen and (min-width: 1px) and (max-width: 767px) {
.calendar-info { padding: 15px; }
.calendar-info h2 { padding: 18px 0 6px; font-size: 20px; }
.calendar-info .duration { margin: 0 0 10px !important; }
#tier2-calendar { padding: 15px; }
.calendar-header { margin-bottom: 12px; }
.day-header { padding: 5px; }
.time-slot { padding: 10px 15px; }
.slots-grid { gap: 12px; }
.confirm-btn { padding: 12px 30px; font-size: 16px; }
.tier2-calendar-wrapper { margin: 0px auto 30px !important; }
}


@media screen and (min-width: 768px) and (max-width: 1024px) {
.calendar-info h2 { padding: 20px 0 8px; font-size: 20px; }
.calendar-info .duration { margin: 0 0 12px !important; }
.calendar-header h2 { font-size: 18px; }
.calendar-header { margin-bottom: 15px; }
.calendar-info { padding: 20px; flex: 0 0 300px; }
#tier2-calendar { padding: 20px; }
.time-slot { padding: 10px; }
.slots-grid { gap: 15px; }
.confirm-btn { padding: 14px 35px; font-size: 17px; }
.tier2-calendar-wrapper { margin: 45px auto !important; }
}


@media screen and (min-width: 1025px) and (max-width: 1200px) {
.calendar-info { padding: 30px; flex: 0 0 380px; }
.calendar-info h2 { padding: 25px 0 8px; font-size: 23px; }
#tier2-calendar { padding: 30px; }
.slots-grid { gap: 18px; }
.confirm-btn { padding: 14px 35px; font-size: 17px; }
.tier2-calendar-wrapper { margin: 65px auto !important; }
}


@media screen and (min-width: 1200px) and (max-width: 1440px) {
.calendar-info { padding: 30px; flex: 0 0 400px; }
#tier2-calendar { padding: 30px; }
.tier2-calendar-wrapper { margin: 80px auto !important; }
}



.selected-date-display {
	color: #1a2b3c;
}

.slots-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 12px;
}

.time-slot {
	padding: 14px 20px;
	border: 1px solid #e5e5e5;
	border-radius: 6px;
	text-align: center;
	font-size: 14px;
	color: #333;
	cursor: pointer;
	transition: all 0.2s;
	position: relative;
}

.time-slot:hover:not(.booked) {
	border-color: #1a2b3c;
	background: #fafafa;
}

.time-slot.booked {
	background: #f5f5f5;
	color: #999;
	cursor: not-allowed;
	text-decoration: line-through;
}

.time-slot.selected {
	border-color: #1a2b3c;
	background: #1a2b3c;
	color: #fff;
}

.selected-badge {
	position: absolute;
	top: -8px;
	right: -8px;
	background: #1a2b3c;
	color: #fff;
	font-size: 9px;
	padding: 2px 6px;
	border-radius: 3px;
	font-weight: 600;
}

/* =====================================================================
 * Confirm button
 * =================================================================== */

.confirm-section {
	margin-top: 24px;
	text-align: right;
}

.confirm-btn {
	background: #1a2b3c;
	color: #fff;
	border: none;
	padding: 16px 32px;
	font-size: 16px;
	font-weight: 600;
	border-radius: 6px;
	cursor: pointer;
	transition: all 0.2s;
}

.confirm-btn:hover {
	background: #2a3b4c;
}

.confirm-btn:disabled {
	background: #ccc;
	cursor: not-allowed;
}

/* =====================================================================
 * Loading / error / empty states
 * =================================================================== */

.loading,
.error,
.no-slots {
	padding: 40px;
	text-align: center;
	color: #666;
}

.error {
	color: #dc3545;
}

/* =====================================================================
 * Responsive — stack on mobile
 * =================================================================== */

@media (max-width: 768px) {
	.tier2-calendar-wrapper {
		flex-direction: column;
		padding: 20px;
	}

	.calendar-info {
		flex: none;
	}

	.slots-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	.calendar-header {
		flex-direction: column;
		gap: 12px;
	}
}

