/* GCal Booking — front-end widget */
.gcb-app {
	--gcb-accent: #b8694a;
	--gcb-text: #141414;
	--gcb-muted: #5f5f5f;
	--gcb-soft: #ececec;
	--gcb-soft-hover: #dedede;
	--gcb-line: #e4e4e4;
	--gcb-danger: #b3261e;
	max-width: 460px;
	margin: 0 auto;
	color: var(--gcb-text);
	font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	font-size: 15px;
	line-height: 1.45;
	text-align: left;
}
.gcb-app *, .gcb-app *::before, .gcb-app *::after { box-sizing: border-box; }

/* Neutralise theme button/input styling */
.gcb-app button {
	appearance: none; -webkit-appearance: none;
	background: none; border: 0; margin: 0; padding: 0;
	font: inherit; color: inherit; line-height: 1.2;
	text-transform: none; letter-spacing: normal; text-shadow: none;
	box-shadow: none; min-height: 0; min-width: 0; width: auto; border-radius: 0;
	cursor: pointer;
}
.gcb-app button:disabled { cursor: default; }
.gcb-app button:focus-visible, .gcb-app a:focus-visible, .gcb-app input:focus-visible {
	outline: 2px solid var(--gcb-accent); outline-offset: 2px;
}
.gcb-app svg { display: block; }

.gcb-card {
	background: #fff;
	border: 1px solid var(--gcb-line);
	border-radius: 16px;
	box-shadow: 0 1px 2px rgba(0,0,0,.04), 0 10px 30px rgba(0,0,0,.05);
	padding: 32px 28px 28px;
}

.gcb-app .gcb-title {
	margin: 0 0 26px; padding: 0;
	font-family: inherit; font-size: 26px; font-weight: 700; line-height: 1.2;
	text-align: center; color: var(--gcb-text); letter-spacing: -.01em;
}
.gcb-app .gcb-head { position: relative; display: flex; align-items: center; justify-content: center; min-height: 36px; margin-bottom: 8px; }
.gcb-app .gcb-head .gcb-title { font-size: 21px; margin: 0; padding: 0 40px; }
.gcb-app .gcb-back {
	position: absolute; left: -6px; top: 50%; transform: translateY(-50%);
	width: 36px; height: 36px; border-radius: 50%;
	display: flex; align-items: center; justify-content: center;
}
.gcb-app .gcb-back:hover { background: var(--gcb-soft); }
.gcb-sub { margin: 0 0 20px; text-align: center; color: var(--gcb-muted); }

/* Month nav */
.gcb-month { display: flex; align-items: center; justify-content: center; gap: 28px; margin-bottom: 22px; }
.gcb-month-label { font-weight: 700; font-size: 17px; min-width: 150px; text-align: center; }
.gcb-app .gcb-nav { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.gcb-app .gcb-nav:hover:not(:disabled) { background: var(--gcb-soft); }
.gcb-app .gcb-nav:disabled { opacity: .25; }

/* Grid */
.gcb-grid {
	display: grid; grid-template-columns: repeat(7, 1fr);
	row-gap: 8px; column-gap: 4px; justify-items: center;
	transition: opacity .15s;
}
.gcb-grid.is-loading { opacity: .45; pointer-events: none; }
.gcb-wd { font-size: 13px; color: #333; padding-bottom: 6px; }
.gcb-cell { width: 100%; display: flex; justify-content: center; }
.gcb-app .gcb-day {
	width: 46px; max-width: 100%; aspect-ratio: 1 / 1;
	border-radius: 50%;
	display: flex; align-items: center; justify-content: center;
	font-size: 16px; color: var(--gcb-text);
}
.gcb-app span.gcb-day { color: #2a2a2a; }
.gcb-app .gcb-day.is-available { background: var(--gcb-soft); }
.gcb-app button.gcb-day.is-available:hover { background: var(--gcb-soft-hover); }
.gcb-app .gcb-day.is-selected, .gcb-app .gcb-day.is-selected:hover { background: var(--gcb-accent); color: #fff; }

.gcb-status { min-height: 20px; margin-top: 12px; font-size: 13px; color: var(--gcb-muted); text-align: center; }
.gcb-app .gcb-linkbtn { color: var(--gcb-accent); font-weight: 600; text-decoration: underline; }

/* Time zone */
.gcb-tz { margin-top: 18px; }
.gcb-tz-label { font-weight: 600; font-size: 15px; margin-bottom: 8px; }
.gcb-tz-row { position: relative; display: flex; align-items: center; gap: 12px; padding: 4px 0; width: fit-content; max-width: 100%; }
.gcb-tz-text { font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gcb-app .gcb-tz-select {
	position: absolute; inset: 0; width: 100%; height: 100%;
	opacity: 0; cursor: pointer; font-size: 16px; margin: 0;
}
.gcb-tz-row:focus-within { outline: 2px solid var(--gcb-accent); outline-offset: 4px; border-radius: 6px; }

/* Time slots */
.gcb-slots { display: flex; flex-direction: column; gap: 10px; max-height: 360px; overflow-y: auto; padding: 2px; }
.gcb-app .gcb-slot {
	flex: none; width: 100%; padding: 13px 16px; border-radius: 10px;
	border: 1.5px solid var(--gcb-accent); color: var(--gcb-accent);
	font-weight: 600; font-size: 16px; text-align: center;
	transition: background .12s, color .12s;
}
.gcb-app .gcb-slot:hover, .gcb-app .gcb-slot.is-selected { background: var(--gcb-accent); color: #fff; }

/* Summary */
.gcb-summary { background: #f6f6f6; border-radius: 12px; padding: 14px 16px; margin: 0 0 20px; display: grid; gap: 8px; font-size: 14px; }
.gcb-summary-row { display: flex; align-items: flex-start; gap: 10px; }
.gcb-summary-row .gcb-ico { color: var(--gcb-muted); flex: none; margin-top: 1px; }
.gcb-summary a { color: var(--gcb-accent); font-weight: 600; }
.gcb-summary.is-old { opacity: .6; text-decoration: line-through; }
.gcb-label { margin: 0 0 6px; font-size: 13px; font-weight: 600; color: var(--gcb-muted); }

/* Form */
.gcb-form { display: grid; gap: 16px; }
.gcb-field label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; }
.gcb-app .gcb-input {
	width: 100%; margin: 0; padding: 11px 13px;
	border: 1px solid #cfcfcf; border-radius: 10px; background: #fff;
	font: inherit; font-size: 16px; color: var(--gcb-text); box-shadow: none; height: auto;
}
.gcb-app .gcb-input:focus { border-color: var(--gcb-accent); outline: 2px solid var(--gcb-accent); outline-offset: 0; }
.gcb-hint { display: block; margin-top: 6px; font-size: 12.5px; color: var(--gcb-muted); }
.gcb-guest-row { display: flex; gap: 8px; }
.gcb-app .gcb-add { padding: 0 16px; border-radius: 10px; border: 1px solid #cfcfcf; font-weight: 600; flex: none; }
.gcb-app .gcb-add:hover { border-color: var(--gcb-accent); color: var(--gcb-accent); }
.gcb-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.gcb-chips:empty { display: none; }
.gcb-chip { display: inline-flex; align-items: center; gap: 4px; background: var(--gcb-soft); border-radius: 999px; padding: 4px 4px 4px 12px; font-size: 13.5px; }
.gcb-app .gcb-chip button { width: 22px; height: 22px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.gcb-app .gcb-chip button:hover { background: var(--gcb-soft-hover); }
.gcb-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }

/* Buttons */
.gcb-app .gcb-btn {
	display: block; width: 100%; padding: 14px 18px; border-radius: 999px;
	background: var(--gcb-accent); color: #fff; border: 1.5px solid var(--gcb-accent);
	font-weight: 600; font-size: 16px; text-align: center; text-decoration: none;
}
.gcb-app .gcb-btn:hover { filter: brightness(.94); color: #fff; }
.gcb-app .gcb-btn:disabled { opacity: .6; filter: none; }
.gcb-app .gcb-btn-outline { background: transparent; color: var(--gcb-accent); }
.gcb-app .gcb-btn-outline:hover { background: var(--gcb-soft); color: var(--gcb-accent); filter: none; }
.gcb-app .gcb-btn-danger { background: var(--gcb-danger); border-color: var(--gcb-danger); }
.gcb-app .gcb-btn-danger-outline { background: transparent; color: var(--gcb-danger); border-color: #e3b9b5; }
.gcb-app .gcb-btn-danger-outline:hover { background: #fbefee; color: var(--gcb-danger); filter: none; }
.gcb-actions { display: grid; gap: 10px; margin-top: 4px; }

/* States */
.gcb-error { background: #fdecea; color: #7d1d14; border-radius: 10px; padding: 10px 13px; font-size: 14px; margin: 14px 0 0; }
.gcb-error:empty { display: none; }
.gcb-note { background: #f6f6f6; border-radius: 10px; padding: 12px 14px; font-size: 14px; margin: 0 0 18px; text-align: center; }
.gcb-done-icon { width: 56px; height: 56px; border-radius: 50%; background: var(--gcb-accent); color: #fff; display: flex; align-items: center; justify-content: center; margin: 0 auto 14px; }
.gcb-done-icon.is-muted { background: var(--gcb-soft); color: var(--gcb-muted); }
.gcb-spinner { width: 28px; height: 28px; margin: 40px auto; border-radius: 50%; border: 3px solid var(--gcb-soft); border-top-color: var(--gcb-accent); animation: gcb-spin .8s linear infinite; }
@keyframes gcb-spin { to { transform: rotate(360deg); } }

@media (max-width: 480px) {
	.gcb-card { padding: 24px 14px 20px; border-radius: 14px; }
	.gcb-app .gcb-title { font-size: 23px; }
	.gcb-month { gap: 14px; }
	.gcb-app .gcb-day { width: 42px; font-size: 15px; }
}
@media (prefers-reduced-motion: reduce) {
	.gcb-spinner { animation-duration: 2.4s; }
	.gcb-grid, .gcb-app .gcb-slot { transition: none; }
}
