#hfwe_calculator_container {
	container: calculator / inline-size;
}

#hfwe_calculator {
	--black: #171717;
	--grayish: #f4f4ef;
	--grayish-02: #e6e7e0;
	--yellowish: #effc5c;
	--sky: #16e4f1; /* branding */
	--iris: #b89bf2; /* copy */
	--melon: #ff6b6b; /* design */
	--peach: #f9cd5d; /* dev */
	--grass: #94e86d; /* seo */
	--calendar-font: 'Shadows Into Light Two', sans-serif;
	width: 100%;
	font-size: 16px;
	border-radius: 20px;
	padding: 8px;
	background-color: #dbdcd6;
	display: -ms-grid;
	display: grid;
	-ms-grid-columns: minmax(auto, 450px) 10px minmax(100px, calc(100% - 450px));
	grid-template-columns: minmax(auto, 450px) minmax(100px, calc(100% - 450px));
	grid-auto-rows: 1fr 1fr;
	gap: 10px;
}

/* form */

#hfwe_calculator form {
	margin: 0;
	padding: 17px 16px;
	border-radius: 16px;
	background-color: white;
}

#hfwe_calculator fieldset {
	padding: 20px;
	border-radius: 8px;
	background-color: var(--grayish);
	margin-bottom: 10px;
	display: flex;
	flex-wrap: wrap;
	gap: 8px 6px;
}

#hfwe_calculator form label {
	margin-bottom: 0;
}

#hfwe_calculator fieldset:last-child {
	margin-bottom: 0;
}

#hfwe_calculator fieldset > span {
	flex: 1 1 100%;
	padding-bottom: 8px;
}

#hfwe_calculator legend {
	font-size: 16px;
	font-weight: 500;
	line-height: 100%;
	letter-spacing: 0.32px;
}

#hfwe_calculator legend span {
	opacity: 0.4;
	font-weight: 400;
}

#hfwe_calculator form label span {
	font-size: 12px;
	font-weight: 700;
	line-height: 18px;
	letter-spacing: 0.96px;
	text-transform: uppercase;
	color: var(--black);
	padding: 2px 8px;
	background-color: white;
	border-radius: 70px;
	cursor: pointer;
	-webkit-user-select: none;
	-moz-user-select: none;
	-ms-user-select: none;
	user-select: none;
}

#hfwe_calculator form label input:checked + span {
	color: white;
	background-color: var(--black);
}

#hfwe_calculator form label pre {
	font-size: 16px;
	font-weight: 700;
	letter-spacing: -0.32px;
	display: inline;
	margin: 0;
}

#pages_slider + label {
	width: 100%;
	display: flex;
	justify-content: space-between;
}

#pages_slider {
	-webkit-appearance: none;
	width: 100%;
	height: 3px;
	background: rgba(0, 0, 0, 0.1);
	border-radius: 5px;
	background-image: linear-gradient(var(--black), var(--black));
	background-repeat: no-repeat;
}

#pages_slider::-webkit-slider-thumb {
	-webkit-appearance: none;
	height: 20px;
	width: 20px;
	border-radius: 50%;
	background: var(--black);
	cursor: ew-resize;
	-webkit-transition: background 0.3s ease-in-out;
	transition: background 0.3s ease-in-out;
	cursor: -webkit-grab;
	cursor: grab;
}

#pages_slider::-webkit-slider-runnable-track {
	-webkit-appearance: none;
	box-shadow: none;
	border: none;
}

/* calendar */

#hfwe_calendar {
	border-radius: 16px;
	background-color: white;
	display: flex;
	flex-direction: column;
}

#hfwe_calendar_content {
	flex: 1;
	position: relative;
	display: flex;
}

#hfwe_calendar footer {
	margin: 0 16px 10px;
	padding: 13px 20px;
	border-radius: 8px;
	background: var(--grayish);
	display: flex;
	gap: 30px;
	align-items: center;
	flex-wrap: wrap;
}

#hfwe_calendar footer small {
	font-size: 10px;
	font-weight: 500;
	line-height: 14px;
	letter-spacing: 0.5px;
	text-transform: uppercase;
}

#hfwe_calendar footer p {
	margin: 0;
	font-size: 24px;
	font-style: normal;
	font-weight: 700;
	line-height: normal;
	letter-spacing: 0.48px;
	text-transform: capitalize;
}

#hfwe_calendar footer button {
	margin-left: auto;
	border-radius: 85px;
	background-color: white;
	display: inline-flex;
	gap: 10px;
	align-items: center;
	font-size: 11px;
	font-weight: 900;
	line-height: 100%;
	letter-spacing: 0.33px;
	text-transform: uppercase;
	padding: 17px 23px;
	width: 169px;
}

#hfwe_calendar footer button path {
	fill: var(--yellowish);
}

#hfwe_calendar footer button[data-active='true'] {
	background-color: var(--yellowish);
}

#hfwe_calendar footer button[data-active='true'] path {
	fill: black;
}

/* calendar window */

#hfwe_calendar_window {
	overflow-y: scroll;
	cursor: -webkit-grab;
	cursor: grab;
	flex: 1;
	height: 100%;
	scrollbar-width: thin;
	scrollbar-color: var(--yellowish) transparent;
}

#hfwe_calendar_window::-webkit-scrollbar-track {
	background: transparent;
}

#hfwe_calendar_window::-webkit-scrollbar-thumb {
	background-color: var(--yellowish);
	border-radius: 6px;
	border: 3px solid var(--yellowish);
}

#hfwe_calendar_grid {
	display: -ms-grid;
	display: grid;
	padding: 40px 34px 10px;
	min-width: 100%;
	height: 100%;
	min-height: 300px;
	grid-gap: 20px 0;
	max-height: 1px;
}

.hfwe_calendar_top {
	-ms-grid-row: 1;
	-ms-grid-row-span: 1;
	grid-row: 1 / span 1;
	grid-column: 1 / -1;
	/* TODO ask stefan for a straight line */
	background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="843" height="7" viewBox="0 0 843 7" fill="none"><path d="M1 1.73222C175.334 -1.80331 433.607 8.80331 842 5.26778" stroke="%23EFEFEF" stroke-linecap="round" stroke-dasharray="12 12"/></svg>');
	background-repeat: repeat-x;
	background-size: 841px;
	background-position-y: bottom;
	background-position-x: 0px;
}

.hfwe_calendar_header {
	-ms-grid-row: 1;
	-ms-grid-row-span: 1;
	grid-row: 1 / span 1;
	font-family: var(--calendar-font);
	padding-left: 12px;
	padding-bottom: 12px;
	letter-spacing: 0.32px;
	display: flex;
	align-items: center;
}

.hfwe_calendar_col {
	-ms-grid-column-span: 2;
	grid-column: span 2;
	grid-row: 1 / -1;
	background-image: url('data:image/svg+xml;utf8,<svg width="7" height="422" viewBox="0 0 7 422" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M5.26777 1C8.8033 88.0633 -1.8033 217.046 1.73223 421" stroke="%23EFEFEF" stroke-linecap="round" stroke-dasharray="12 12"/></svg>');
	background-repeat: no-repeat;
	background-size: contain;
	background-position: right;
}

/* first column */
.hfwe_calendar_col:first-of-type {
	position: relative;
}
.hfwe_calendar_col:first-of-type::after {
	content: '';
	background-image: url('data:image/svg+xml;utf8,<svg width="7" height="422" viewBox="0 0 7 422" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M5.26777 1C8.8033 88.0633 -1.8033 217.046 1.73223 421" stroke="%23EFEFEF" stroke-linecap="round" stroke-dasharray="12 12"/></svg>');
	background-repeat: no-repeat;
	background-size: contain;
	background-position: left;
	height: 100%;
	position: absolute;
	top: 0;
	left: -8px;
	width: 100%;
}

.hfwe_calendar_entry {
	padding: 6px 20px 6px 18px;
	border-radius: 8px;
	font-size: 14px;
	font-weight: 400;
	letter-spacing: 0.42px;
	display: flex;
	align-items: center;
	z-index: 1;
	cursor: pointer;
	transition: 0.3s opacity;
	position: relative;
}

.hfwe_calendar_entry_bg {
	position: absolute;
	top: 0;
	left: 0;
	bottom: 0;
	width: 100%;
	height: 100%;
	background-color: var(--grayish);
	border-radius: 8px;
	z-index: -1;
	display: flex;
	align-items: center;
	justify-content: flex-end;
	padding-right: 10px;
}

.hfwe_calendar_entry::after {
	content: 'See deliverables';
	position: absolute;
	left: 6px;
	right: 6px;
	text-align: center;
	height: calc(100% - 12px);
	display: flex;
	align-items: center;
	border-radius: 8px;
	justify-content: center;
	visibility: hidden;
	opacity: 0;
	transition: 0.3s;
}

.hfwe_calendar_entry i {
	width: 6px;
	height: calc(100% - 12px);
	border-radius: 8px;
	background-color: white;
	margin-right: 6px;
	flex-shrink: 0;
	position: absolute;
	left: 6px;
	top: 6px;
	transition: 0.3s width;
}

.hfwe_calendar_entry > svg {
	margin-left: auto;
	margin-right: 4px;
}

.hfwe_calendar_entry_text {
	overflow: hidden;
	padding: 2px 0px;
	height: 24px;
	width: 100%;
	z-index: 3;
}

.hfwe_calendar_entry span {
	display: block;
	text-overflow: ellipsis;
	overflow: hidden;
	white-space: nowrap;
	-webkit-user-select: none;
	-moz-user-select: none;
	-ms-user-select: none;
	user-select: none;
	line-height: 20px;
	transition: 0.3s;
}

.hfwe_calendar_entry span:last-child {
	text-align: center;
	width: 100%;
	padding-top: 2px;
	min-width: 162px;
}

.hfwe_calendar_entry:hover span {
	-webkit-transform: translateY(-22px);
	transform: translateY(-22px);
}

.hfwe_calendar_entry:hover i {
	width: calc(100% - 12px);
}

/* Colors */

.hfwe_calendar_entry[data-service='discovery'] i,
.hfwe_calendar_entry[data-service='discovery']::after {
	background-color: #fb5454;
}
.hfwe_calendar_entry[data-service='branding'] i,
.hfwe_calendar_entry[data-service='branding']::after {
	background-color: #9f6fff;
}
.hfwe_calendar_entry[data-service='copywriting'] i,
.hfwe_calendar_entry[data-service='copywriting']::after {
	background-color: #ffa34e;
}
.hfwe_calendar_entry[data-service='wireframes'] i,
.hfwe_calendar_entry[data-service='wireframes']::after {
	background-color: #ffa34e;
}
.hfwe_calendar_entry[data-service='design'] i,
.hfwe_calendar_entry[data-service='design']::after {
	background-color: #ffa34e;
}
.hfwe_calendar_entry[data-service='dev'] i,
.hfwe_calendar_entry[data-service='dev']::after {
	background-color: #5560fa;
}
.hfwe_calendar_entry[data-service='technical seo'] i,
.hfwe_calendar_entry[data-service='technical seo']::after {
	background-color: #5560fa;
}
.hfwe_calendar_entry[data-service='google analytics setup'] i,
.hfwe_calendar_entry[data-service='google analytics setup']::after {
	background-color: #fac93a;
}
.hfwe_calendar_entry[data-service='seo'] i,
.hfwe_calendar_entry[data-service='seo']::after {
	background-color: #fb5454;
}

#hfwe_calendar[data-calendar-info='on']
	.hfwe_calendar_entry[data-service-info='off'] {
	opacity: 0.3;
}

/* Calendar Info */

#hfwe_deliverables {
	position: absolute;
	top: 16px;
	right: 16px;
	bottom: 16px;
	width: calc(100% - 32px);
	max-width: 320px;
	z-index: 99;
	overflow-y: auto;
	background-color: var(--grayish);
	border-radius: 16px;
	padding: 20px 25px;
	font-size: 14px;
	font-weight: 500;
	letter-spacing: 0.42px;
	visibility: hidden;
}

#hfwe_calendar[data-calendar-info='on'] #hfwe_deliverables {
	visibility: visible;
}

.hfwe_deliverables_close {
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	background: transparent;
	padding-left: 12px;
	padding-bottom: 15px;
}

#hfwe_deliverables span {
	margin-bottom: 15px;
	display: flex;
}

#hfwe_deliverables section {
	margin-bottom: 20px;
}

#hfwe_deliverables section:first-of-type {
	display: flex;
	justify-content: space-between;
	border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.hfwe_deliverables_line {
	font-weight: 400;
	align-items: center;
	padding: 6px;
	border-radius: 8px;
	background-color: var(--grayish-02);
	margin-bottom: 5px !important;
	display: -ms-grid !important;
	display: grid !important;
	-ms-grid-columns: 6px 6px 1fr 6px 16px;
	grid-template-columns: 6px 1fr 16px;
	grid-gap: 6px;
	line-height: 1.1;
}

.hfwe_deliverables_line i {
	width: 6px;
	height: 100%;
	border-radius: 8px;
	background-color: white;
	margin-right: 6px;
	flex-shrink: 0;
}

.hfwe_deliverables_line[data-included='always'] i,
.hfwe_deliverables_line[data-included='yes'] i {
	background-color: var(--grass);
}

.hfwe_deliverables_line[data-included='no'] i {
	background-color: #d1d1d1;
}

.hfwe_deliverables_line[data-included='yes'],
.hfwe_deliverables_line[data-included='no'] {
	cursor: pointer;
}

/* Mobile */

@container calculator (max-width: 1100px) {
	#hfwe_calculator {
		display: flex;
		flex-direction: column;
	}

	#hfwe_calendar_grid {
		min-height: 450px;
	}
}

@container calculator (max-width: 650px) {
	#hfwe_calendar footer {
		justify-content: center;
		gap: 10px;
	}

	#hfwe_calendar footer button {
		margin-left: unset;
	}
}
