@import url('https://fonts.googleapis.com/css?family=Rubik:200,300,400,500,bold&display=swap');
body {
	background: #D8EEFE;
	font-size: 18px;
	font-family: "Rubik";
	margin: 16px;
	font-weight: normal;
}

body.open {
	height: 100vh;
	overflow-y: hidden;
  }

body > header > form {
	display: flex;
	gap: 20px;
	margin-bottom: 47px;
}
body > header > div { 
	display: flex;
	margin-bottom: 2rem;
	margin-top: 2rem;
}

h1 {
	margin: 0;
	font-family: Rubik;
	font-style: normal;
	font-weight: bold;
	font-size: 2.5rem;
    line-height: 100%;
	color: #094067;
}

button {
    border: none;
    background-color: transparent;
}

input {
	padding: 8px;
	border: none;
	background: #D8EEFE;
	font-size: 16px;
	color: #094067;
	border-radius: 5px;
}

.svg_icon {
	width: 23px;
	height: 23px;
}

/* Header form */

.add {
	background: #EF4565;
	border-radius: 5px;
	font-style: normal;
	font-weight: 500;
	font-size: 18px;
	border: none;
	color: #FFFFFE;
	padding: 15px 20px;
	cursor: pointer;
	outline: none;
	line-height: 21px;
}
.add:hover {
	color: #FFFFFE;
} 
.search, .select{
	padding: 15px 20px;
	background: #FFFFFE;
	border-radius: 5px;
	border: none;
	font-weight: 500;
	font-size: 18px;
	line-height: 21px;
	color: #5F6C7B;
	outline: none;
	cursor: pointer;
}

.search {
	width: 264px;
}
.form-inline .select {
	width: 282px;
	display: inline-block;
    width: auto;
    vertical-align: middle;
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	background: url(./images/down_arrow.svg) #FFFFFE no-repeat calc(100% - 21px) !important;
	padding-inline-end: 3rem;
}

.select > option {
	color: #D8EEFE !important;
	background: #094067 !important;
}

/* List */
.cards {
	display: flex;
	flex-direction: column;
	margin-bottom: 1rem;
	max-width: 100%;
    min-width: 100%;
}

.card_item {
	background: #FFFFFE;
	border-radius: 5px;
	display: flex;
	flex-direction: column;
	padding-block-start: 22px;
	padding-block-end: 22px;
	padding-inline-start: 43px;
	padding-inline-end: 25px;
	gap: 16px;
	margin-bottom: 32px;
} 

.card_item:last-of-type {
	margin-bottom: 0;
}

.item_fig {
	margin: 0;
	margin-inline-end: 39px;
}


.item_fig img {
	width: 92px;
	height: 94px;
	border-radius: 5px;
}

.item_row:first-of-type {
	margin-inline-end: auto;
}

.even, .odds {
	background-color: #fffffe;
	color: #5F6C7B;
}

.birthday {
	background-color: rgba(255, 255, 255, 0.8);
}

.age {
	color: #EF4565;
}

.upcoming_birthday {
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: stretch;
	align-self: flex-start;
}
.upcoming_birthday > span {
	align-self: flex-end;
	font-weight: 500;
	font-size: 18px;
	line-height: normal;
	color: #5F6C7B;
}

.upcoming_birthday button {
	padding: 0;
	outline: none;
	opacity: .8;
	transition: all .01s;
}

.upcoming_birthday button:hover {
	opacity: 1;
}

.name {
	font-weight: 500;
	font-size: 20px;
	line-height: normal;
	color: #000000;
}

.turning_age {
	font-weight: 500;
	font-size: 18px;
	line-height: normal;

	color: #5F6C7B;

}

/* popup */

.popup {
	background: rgba(255, 255, 255, 0.8);
	position: fixed;
	height: 100vh;
	width: 100vw;
	transition: all 0.25s;
	top: 0;
	display: grid;
	align-items: center;
	pointer-events: none;
	opacity: 0;
	transition: all .5s;
	left: 0;
}

.popup fieldset {
	padding: 0;
	background-color: white;
	border-radius: 5px;
	transition: all 0.5s;
    margin: auto;
}

.popup fieldset > div {
	display: flex;
	flex-direction: column;
	margin: 2rem;
}

.popup label {
	font-weight: 500;
	font-size: 18px;
	color: #094067;
}

.popup ::placeholder {
	font-weight: 500;
	font-size: 18px;
	color: #094067;
  }

.popup input {
	content: attr(value);
	font-weight: 500;
	font-size: 18px;
	color: #094067;
}

#Birthday {
	content: attr(value);
	font-weight: 500;
	font-size: 18px;
	color: #094067;
}

#Birthday:focus::before,
#Birthday:valid::before {
	display: none;
}

.popup.open {
	opacity: 1;
	pointer-events: all;
}
.options-btn {
	display: flex;
	flex-wrap: wrap;
	gap: 20px;
	margin-top: 20px;
}

.popup button {
	position:relative;
	background: #FFFFFF;
	padding: 14px 20px;
	border: none;
	cursor: pointer;
	border-radius: 5px;
	opacity: 0.9;
	width: 158px;
	line-height: 21px;
	transition: all .5s;
	margin: 0;
}

.popup button:first-of-type {
	background-color: #EF4565;
	color: #FFFFFF;
}

.popup button:first-of-type:hover {
	background-color: #ee2247;
}

.popup button:last-of-type {
	border: 2px solid #5F6C7B;
}
.popup button:hover {
	box-shadow: inset 0px 0px 2px, 0px 6px 0px #094067;
}

fieldset {
	display: flex;
}

.popup input {
	max-width: 80%;
	margin-bottom: 11px;
}
.popup strong {
	font-size: 20px;
	font-weight: 700;
	color: #EF4565;

}

.buttons {
	display: flex;
	justify-content: flex-start;
	gap: 16px;
}
.form-inline {
	align-items: flex-end;
	gap: 35px;
}
.form-inline > div {
	max-width: 100%;
    min-width: 100%;
}
.form-inline label {
	font-style: normal;
	font-weight: 500;
	font-size: 18px;
	line-height: 21px;
	text-align: left;
	color: #094067;
	margin-bottom: 13px;
}

.form-inline input, .form-inline select {
	max-width: 100%;
    min-width: 100%;
}

.close {
	align-self: flex-end;
	cursor: pointer;
}

/* From tablet */
@media (min-width: 779px) {
	body {
		max-width: 779px;
		min-width: 779px;
		margin: auto;
		margin-top: 63px;
		margin-bottom: 63px;
	}

	h1 {
		font-size: 64px;
		line-height: 76px;
	}

	h2 {
		font-weight: 500;
		font-size: 48px;
	}
	
	/* Heaer form */

	.form-inline {
		justify-content: center;
	}

	.form-inline > div {
		width: 264px;
		min-width: unset;
	}

	/* Popup modal */

	.popup fieldset {
		width: 779px;
	}

	.popup fieldset > div {
		max-width: 70%;
		margin: auto;
		margin-right: 63px;
		margin-top: 53px;
		margin-bottom: 60px;
	}

	.popup input {
		width: 264px;
	}

	/* List */

	.card_item {
		flex-direction: row;
		align-items: center;
		justify-content: space-between;
	}
	.upcoming_birthday {
		gap: 38px;
	}
	.upcoming_birthday > span {
		font-size: 24px;
		line-height: 28px;
	}
	.buttons {
		justify-content: flex-end;
	}
	.name {
		font-size: 36px;
		line-height: 43px;
	}

	.turning_age {
		font-size: 24px;
		line-height: 28px;
	}
}

/* On a big desktop view*/

@media (min-width: 1440px) {
	.popup fieldset {
		width: 1079px;
		height: 751px;
		margin-top: 16vh;
		margin-bottom: 11vh;
		max-height: 73vh;
	}

	.popup fieldset > div {
		width: 1114px;
		margin-left: 263px;
		margin-right: 64px;
		margin-top: 6vh;
		margin-bottom: 6vh;
	}

	.close {
		position: relative;
    	top: -12px;
	}
}

