/* Casa Campana – booking side panel.
   Set the two font variables to your theme fonts (serif headings, sans body). */
.cc-panel {
	--cc-font-serif: var(--font-heading, "Instrument Serif", Georgia, serif);
	--cc-font-sans: var(--font-body, "Quicksand", system-ui, sans-serif);
	--cc-ink: #1f1d12;
	--cc-muted: #c7c3b7;
	--cc-line: #e7e3d9;
	--cc-field: #cfcabd;
	--cc-paper: #fdfcf8;
	--cc-hover: #f2eee4;

	position: fixed; inset: 0; z-index: 9999;
	visibility: hidden; pointer-events: none;
	font-family: var(--cc-font-sans); color: var(--cc-ink);
}
.cc-panel.is-open { visibility: visible; pointer-events: auto; }

.cc-panel__overlay {
	position: absolute; inset: 0;
	background: rgba(30, 28, 14, .72);
	opacity: 0; transition: opacity .3s ease;
}
.cc-panel.is-open .cc-panel__overlay { opacity: 1; }

.cc-panel__drawer {
	position: absolute; top: 0; right: 0; height: 100%;
	width: min(560px, 100%);
	background: var(--cc-paper);
	overflow-y: auto; padding: 44px;
	transform: translateX(100%); transition: transform .4s cubic-bezier(.2, .7, .2, 1);
}
.cc-panel.is-open .cc-panel__drawer { transform: none; }
body.cc-panel-open { overflow: hidden; }

/* Head */
.cc-panel__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; margin-bottom: 52px; }
.cc-panel__title {
	margin: 0; max-width: 340px;
	font-family: var(--cc-font-serif); font-weight: 400;
	font-size: 30px; line-height: 1.4; letter-spacing: -.01em;
}
.cc-panel__close {
	flex-shrink: 0; display: inline-flex; align-items: center; gap: 14px;
	height: 40px; padding: 0 14px;
	border: 0; background: var(--cc-ink); color: var(--cc-paper);
	font-family: var(--cc-font-serif); font-size: 15px; cursor: pointer;
}

/* Fields */
.cc-panel__label {
	display: block; margin: 0 0 10px;
	font-size: 14px; letter-spacing: .02em; text-transform: uppercase;
}
.cc-panel__select-wrap { position: relative; margin-bottom: 50px; }
.cc-panel__select-wrap::after {
	content: ""; position: absolute; right: 22px; top: 50%;
	width: 8px; height: 8px; margin-top: -6px;
	border-right: 1.5px solid var(--cc-ink); border-bottom: 1.5px solid var(--cc-ink);
	transform: rotate(45deg); pointer-events: none;
}
.cc-panel__select {
	width: 100%; height: 46px; padding: 0 48px 0 16px;
	appearance: none; -webkit-appearance: none;
	border: 1px solid var(--cc-field); border-radius: 0;
	background: var(--cc-paper); color: var(--cc-ink);
	font: 16px/1 var(--cc-font-sans); cursor: pointer;
}

/* Calendar */
.cc-cal { border-top: 1px solid var(--cc-line); }
.cc-cal.is-loading { opacity: .5; pointer-events: none; }

.cc-cal__nav { display: flex; align-items: center; justify-content: space-between; height: 44px; }
.cc-cal__month { font-size: 16px; font-weight: 500; }
.cc-cal__arrow {
	display: grid; place-items: center; width: 40px; height: 40px;
	border: 0; background: none; color: var(--cc-ink); cursor: pointer;
}
.cc-cal__arrow:disabled { color: var(--cc-muted); cursor: default; }

.cc-cal__weekdays,
.cc-cal__grid { display: grid; grid-template-columns: repeat(7, 1fr); text-align: center; }

.cc-cal__weekdays { border-top: 1px solid var(--cc-line); border-bottom: 1px solid var(--cc-line); }
.cc-cal__weekdays span { height: 40px; line-height: 40px; font-size: 14px; text-transform: uppercase; }

.cc-cal__day {
	position: relative; height: 40px;
	border: 0; border-bottom: 1px solid var(--cc-line); border-radius: 0;
	background: none; color: var(--cc-ink);
	font: 600 14px/1 var(--cc-font-sans); cursor: pointer;
}
.cc-cal__day.is-empty { display: block; }
.cc-cal__day:not(:disabled):not(.is-start):not(.is-end):not(.is-in-range):hover { background: var(--cc-hover); }
.cc-cal__day:disabled { cursor: default; }

/* Past / not selectable */
.cc-cal__day.is-past,
.cc-cal__day:disabled { color: var(--cc-muted); font-weight: 400; }

/* Booked – thin X over the number */
.cc-cal__day.is-booked { color: var(--cc-muted); font-weight: 400; }
.cc-cal__day.is-booked::before,
.cc-cal__day.is-booked::after {
	content: ""; position: absolute; left: 50%; top: 50%;
	width: 17px; height: 1px; background: #a9a597;
	transform: translate(-50%, -50%) rotate(45deg);
}
.cc-cal__day.is-booked::after { transform: translate(-50%, -50%) rotate(-45deg); }

/* A booked day that is the first free check-out stays selectable */
.cc-cal__day.is-booked:not(:disabled) { cursor: pointer; }

/* Selected range */
.cc-cal__day.is-start,
.cc-cal__day.is-end,
.cc-cal__day.is-in-range {
	background: var(--cc-ink); color: #fff; font-weight: 600;
	border-bottom-color: var(--cc-ink);
}
.cc-cal__day.is-end.is-booked::before,
.cc-cal__day.is-end.is-booked::after { display: none; }

.cc-cal__day:focus-visible,
.cc-cal__arrow:focus-visible,
.cc-panel__close:focus-visible,
.cc-panel__select:focus-visible,
.cc-panel__next:focus-visible { outline: 2px solid var(--cc-ink); outline-offset: 2px; }
.cc-cal__day:focus-visible { outline-offset: -2px; }

/* Message + CTA */
.cc-panel__msg { margin: 16px 0 0; font-size: 14px; line-height: 1.5; }
.cc-panel__msg:empty { display: none; }

/* Casa Campana only: static destination, clickable booked nights (Villa Firenze hint), message links. */
.cc-panel__select-wrap--static::after { display: none; }
.cc-panel__select-wrap--static .cc-panel__select { display: flex; align-items: center; cursor: default; }
.cc-cal__day.is-booked[aria-disabled="true"] { cursor: not-allowed; }
.cc-cal__day.is-booked[aria-disabled="true"]:hover { background: none !important; }
.cc-panel__msg a, .casa-search__msg a, .cc-res__error a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.cc-panel__next {
	display: block; width: 100%; height: 40px; margin-top: 40px;
	border: 0; background: var(--cc-ink); color: #fff;
	font-family: var(--cc-font-serif); font-size: 15px; cursor: pointer;
}
.cc-panel__next:disabled { opacity: .5; cursor: default; }

@media (max-width: 600px) {
	.cc-panel__drawer { padding: 24px 20px; }
	.cc-panel__head { margin-bottom: 36px; }
	.cc-panel__title { font-size: 24px; }
	.cc-cal__weekdays span { font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
	.cc-panel__drawer, .cc-panel__overlay { transition: none; }
}


/* Reservation page – [casa_reservation] */
.cc-res {
	--r-serif: var(--font-heading, "Instrument Serif", Georgia, serif);
	--r-sans: var(--font-body, "Quicksand", system-ui, sans-serif);
	--r-ink: #342610; --r-text: #1f1e10; --r-muted: #8f8a7b; --r-soft: #a8a393;
	--r-line: #e7e3d9; --r-field: #d9d4c7; --r-cream: #faefdd; --r-paper: #fdfcf9;
	--r-green: #11552f; --r-btn: #333d3a;
	background: var(--r-paper); color: var(--r-text); font-family: var(--r-sans);
}
.cc-res *, .cc-res *::before, .cc-res *::after { box-sizing: border-box; }
.cc-res .screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Hero */
.cc-res__hero { background: var(--r-cream); text-align: center; padding: 150px 20px 64px; }
.cc-res__leaf { display: inline-block; color: #7d6a4a; margin-bottom: 14px; }
.cc-res__title { margin: 0 0 18px; font-family: var(--r-serif); font-weight: 400; font-size: 64px; line-height: 1.05; letter-spacing: -.02em; color: var(--r-ink); }
.cc-res__intro { max-width: 580px; margin: 0 auto; font-size: 16px; line-height: 1.55; color: #8a7d63; }

/* Layout */
.cc-res__wrap { max-width: 992px; margin: 0 auto; padding: 56px 20px 96px; }
.cc-res__wrap--center { text-align: center; }
.cc-res__grid { display: grid; grid-template-columns: minmax(0, 1fr) 316px; gap: 52px; align-items: start; }
.cc-res__lead { margin: 0 0 24px; font-size: 16px; }
.cc-res__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.cc-res__error { margin: 0 0 28px; padding: 12px 16px; background: #f5d9d9; color: #7a1f1f; font-size: 14px; }

/* Shared text */
.cc-res__k { display: block; margin-bottom: 8px; font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--r-muted); }
.cc-res__v { display: block; font-family: var(--r-serif); font-size: 20px; line-height: 1.2; color: var(--r-ink); }
.cc-res__v--lg { font-size: 27px; }
.cc-res__muted { color: var(--r-soft); }

/* Sections */
.cc-res__section { margin-bottom: 64px; }
.cc-res__section:last-child { margin-bottom: 0; }
.cc-res__h { display: flex; align-items: baseline; gap: 12px; margin: 0 0 26px; font-family: var(--r-serif); font-weight: 400; font-size: 34px; line-height: 1.1; color: var(--r-ink); }
.cc-res__h span { font-size: 12px; color: var(--r-green); }

/* 01 Stay */
.cc-res__dates {
	display: grid; grid-template-columns: 1fr 32px 1fr; width: 100%; padding: 0; text-align: left;
	border: 1px solid var(--r-line); background: #fff; cursor: pointer; font: inherit; color: inherit;
}
.cc-res__dates:hover .cc-res__v--lg { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.cc-res__dates:focus-visible { outline: 2px solid var(--r-ink); outline-offset: 2px; }
.cc-res__date { padding: 28px; }
.cc-res__dates-arrow { display: grid; place-items: center; background: var(--r-cream); color: var(--r-green); }
.cc-res__note { display: flex; align-items: center; gap: 6px; margin-top: 12px; font-size: 11px; color: var(--r-muted); }
.cc-res__facts { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 22px; border: 1px solid var(--r-line); background: #fff; }
.cc-res__facts > div { padding: 20px 24px; }
.cc-res__facts > div + div { border-left: 1px solid var(--r-line); }
.cc-res__stepper { display: inline-flex; align-items: center; gap: 14px; }
.cc-res__stepper button { width: 22px; height: 22px; padding: 0; border: 1px solid #cfcabd; background: #fff; color: var(--r-ink); font-size: 14px; line-height: 1; cursor: pointer; }
.cc-res__stepper button:hover { background: var(--r-cream); }
.cc-res__stepper input { width: 26px; padding: 0; border: 0; background: none; text-align: center; font-family: var(--r-serif); font-size: 20px; color: var(--r-ink); -moz-appearance: textfield; }
.cc-res__stepper input::-webkit-inner-spin-button, .cc-res__stepper input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }

/* 02 / 03 fields */
.cc-res__row { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; margin-bottom: 30px; align-items: end; }
.cc-res__line input, .cc-res__select select, .cc-res__promo input {
	width: 100%; border: 0; border-bottom: 1px solid var(--r-field); border-radius: 0; background: transparent;
	color: var(--r-ink); outline: none;
}
.cc-res__line input { padding: 10px 0; font-family: var(--r-serif); font-size: 17px; }
.cc-res__line input::placeholder { color: var(--r-ink); opacity: 1; }
.cc-res__line input:focus, .cc-res__select select:focus, .cc-res__promo input:focus { border-bottom-color: var(--r-ink); }
.cc-res__line input.is-invalid { border-bottom-color: #b3261e; }
.cc-res__line input.is-invalid::placeholder { color: #b3261e; }
.cc-res__select select {
	padding: 8px 20px 10px 0; font: 14px var(--r-sans); cursor: pointer;
	-webkit-appearance: none; appearance: none;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' fill='none'%3E%3Cpath d='m1 1 4 4 4-4' stroke='%238f8a7b'/%3E%3C/svg%3E") no-repeat right 4px center;
}
.cc-res__transfers { display: flex; flex-wrap: wrap; gap: 12px; margin: 0 0 30px; padding: 0; border: 0; }
.cc-res__transfers legend { padding: 0; margin-bottom: 12px; }
.cc-res__transfer { position: relative; display: flex; flex-direction: column; gap: 4px; padding: 16px 16px 14px; border: 1px solid var(--r-line); background: #fff; cursor: pointer; transition: background .2s, border-color .2s; }
.cc-res__transfer input { position: absolute; opacity: 0; pointer-events: none; }
.cc-res__transfer:hover { border-color: #cfcabd; }
.cc-res__transfer:has(input:checked) { background: var(--r-cream); border-color: var(--r-ink); }
.cc-res__transfer:has(input:focus-visible) { outline: 2px solid var(--r-ink); outline-offset: 2px; }
.cc-res__transfer-t { font-family: var(--r-serif); font-size: 17px; color: var(--r-ink); }
.cc-res__transfer-d { font-size: 10px; color: var(--r-muted); }
.cc-res__textarea { display: block; width: 100%; min-height: 120px; padding: 20px; border: 1px solid var(--r-field); border-radius: 0; background: #fff; font: 14px/1.6 var(--r-sans); color: var(--r-text); resize: vertical; outline: none; }
.cc-res__textarea::placeholder { color: var(--r-soft); }
.cc-res__textarea:focus { border-color: var(--r-ink); }

/* Summary card */
.cc-res__aside { position: sticky; top: calc(var(--wp-admin--admin-bar--height, 0px) + 24px); }
.cc-res__card { background: #fff; border: 1px solid #ebe7dd; box-shadow: 0 14px 34px rgba(31, 30, 16, .07); }
.cc-res__media { position: relative; height: 168px; background: #6b6552 center/cover no-repeat; }
.cc-res__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(20, 18, 8, .72), rgba(20, 18, 8, 0) 65%); }
.cc-res__media-text { position: absolute; left: 20px; right: 20px; bottom: 14px; z-index: 1; color: #fff; }
.cc-res__media-title { display: block; font-family: var(--r-serif); font-size: 20px; line-height: 1.2; }
.cc-res__media-loc { display: flex; align-items: center; gap: 5px; margin-top: 4px; font-size: 10px; opacity: .85; }
.cc-res__stats { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid var(--r-line); }
.cc-res__stats > div { padding: 14px 16px; }
.cc-res__stats > div + div { border-left: 1px solid var(--r-line); }
.cc-res__stats .cc-res__k, .cc-res__trip .cc-res__k { font-size: 8px; margin-bottom: 4px; }
.cc-res__stats .cc-res__v { font-size: 15px; }
.cc-res__block { padding: 22px 20px; border-bottom: 1px solid var(--r-line); }
.cc-res__trip { display: flex; align-items: flex-end; gap: 14px; margin-bottom: 18px; }
.cc-res__trip .cc-res__v { font-size: 18px; }
.cc-res__trip-arrow { color: var(--r-green); padding-bottom: 6px; }
.cc-res__party { margin-left: auto; text-align: right; }
.cc-res__lines { margin: 0; padding: 0 0 16px; list-style: none; border-bottom: 1px solid var(--r-field); }
.cc-res__lines li { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; font-size: 11px; color: #5f5a4c; }
.cc-res__total { display: flex; justify-content: space-between; align-items: baseline; padding-top: 16px; font-family: var(--r-serif); color: var(--r-ink); }
.cc-res__total > span:first-child { font-size: 18px; }
.cc-res__total > span:last-child { font-size: 27px; line-height: 1; }
.cc-res__total .cc-res__muted { font-size: 16px; }
.cc-res__hold { margin: 12px 0 16px; font-size: 9px; color: var(--r-soft); }
.cc-res__cta { display: inline-flex; align-items: center; justify-content: center; gap: 10px; width: 100%; height: 46px; padding: 0 24px; border: 0; background: var(--r-btn); color: #fff; font-family: var(--r-serif); font-size: 17px; text-decoration: none; cursor: pointer; transition: opacity .2s; }
.cc-res__cta:hover { opacity: .92; color: #fff; }
.cc-res__cta:disabled { opacity: .45; cursor: not-allowed; }
.cc-res__cta--inline { width: auto; }
.cc-res__checks { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 12px; margin: 6px 0 0; padding: 0; list-style: none; }
.cc-res__checks li, .cc-res__trust li { display: flex; align-items: center; gap: 7px; font-size: 10px; color: #4b473b; }
.cc-res__checks svg, .cc-res__trust svg { flex-shrink: 0; color: var(--r-green); }
.cc-res__offers { margin: 0 0 16px; padding: 0; list-style: none; }
.cc-res__offers li { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--r-line); font-family: var(--r-serif); font-size: 15px; color: var(--r-ink); }
.cc-res__offers li span + span { color: var(--r-green); }
.cc-res__promo { display: flex; align-items: flex-end; gap: 10px; }
.cc-res__promo label { flex: 1; }
.cc-res__promo .cc-res__k { font-size: 8px; margin-bottom: 2px; }
.cc-res__promo input { padding: 4px 0 6px; font: 12px var(--r-sans); letter-spacing: .06em; }
.cc-res__promo input::placeholder { color: var(--r-soft); }
.cc-res__promo button { height: 32px; padding: 0 14px; border: 1px solid #cfcabd; background: #fff; font-family: var(--r-serif); font-size: 14px; color: var(--r-ink); cursor: pointer; }
.cc-res__promo button:hover { background: var(--r-cream); }
.cc-res__promo-msg { margin: 10px 0 0; font-size: 11px; line-height: 1.5; color: var(--r-green); }
.cc-res__promo-msg:empty { display: none; }
.cc-res__trust { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 12px; margin: 0; padding: 18px 20px; list-style: none; background: var(--r-cream); }

@media (max-width: 960px) {
	.cc-res__grid { grid-template-columns: 1fr; gap: 48px; }
	.cc-res__aside { position: static; max-width: 520px; }
}
@media (max-width: 600px) {
	.cc-res__hero { padding: 120px 16px 44px; }
	.cc-res__title { font-size: 42px; }
	.cc-res__intro { font-size: 15px; }
	.cc-res__wrap { padding: 40px 16px 72px; }
	.cc-res__h { font-size: 28px; }
	.cc-res__dates { grid-template-columns: 1fr; }
	.cc-res__date { padding: 20px; }
	.cc-res__dates-arrow { height: 28px; }
	.cc-res__dates-arrow svg { transform: rotate(90deg); }
	.cc-res__v--lg { font-size: 24px; }
	.cc-res__facts { grid-template-columns: 1fr 1fr; }
	.cc-res__facts > div:last-child { grid-column: 1 / -1; border-left: 0; border-top: 1px solid var(--r-line); }
	.cc-res__row { grid-template-columns: 1fr; gap: 26px; }
	.cc-res__transfer { flex: 1 1 100%; }
}
@media (prefers-reduced-motion: reduce) { .cc-res__transfer, .cc-res__cta { transition: none; } }
