/* ============================================================
   CONTACT & SOCIAL LINKS
   ============================================================ */

/* --- icon buttons --- */

.social-links {
	display: flex;
	gap: 4px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.social-links a {
	position: relative;
	display: grid;
	place-items: center;
	width: 32px;
	height: 36px;
	border-radius: 4px;
	transition: background-color 0.2s var(--ease);
}

/* Frame drawn as two 8px brackets with an open gap between them. */
.social-links a::before,
.social-links a::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	height: 8px;
	border: 1px solid var(--mocha);
	pointer-events: none;
	transition: border-color 0.2s var(--ease);
}

.social-links a::before {
	top: 0;
	border-bottom: 0;
	border-radius: 4px 4px 0 0;
}

.social-links a::after {
	bottom: 0;
	border-top: 0;
	border-radius: 0 0 4px 4px;
}

.social-links a:hover,
.social-links a:focus-visible {
	background: rgba(123, 91, 69, 0.35);
}

.social-links a:hover::before,
.social-links a:hover::after,
.social-links a:focus-visible::before,
.social-links a:focus-visible::after {
	border-color: var(--cream);
}

.social-links img {
	width: 16px;
	height: 16px;
}

/* --- text contacts --- */

.contact-links {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.contact-links a {
	color: var(--cream);
	font-size: 18px;
	line-height: 1.3;
	transition: opacity 0.2s var(--ease);
}

.contact-links a:hover,
.contact-links a:focus-visible {
	opacity: 0.7;
}

/* --- footer --- */

@media (max-width: 767px) {
	.footer__contacts {
		align-items: center;
	}
}

/* --- header --- */

.header-contacts {
	display: flex;
	align-items: center;
	flex: none;
}

.header-contacts .contact-links {
	display: none;
}

.header-contacts .social-links a {
	height: 32px;
}

/* Keeps the icons next to the CTA button instead of spread by space-between. */
@media (min-width: 768px) {
	.header .centered-menu-wrap .main-nav > #menu-top-left-menu,
	.header .centered-menu-wrap .main-nav > #menu-top-right-menu {
		margin-left: auto;
	}
}

/* Tablet: compact sizing so the header fits on one row. */
@media (min-width: 768px) and (max-width: 991px) {
	.header .centered-menu-wrap .main-nav {
		gap: 8px;
	}

	.header .centered-menu-wrap .main-nav > #menu-top-left-menu > li > a {
		padding-left: 3px;
		padding-right: 3px;
	}

	.header .centered-menu-wrap .main-nav .accent-navigation li a {
		padding-left: 10px;
		padding-right: 10px;
	}

	.header-contacts {
		order: 2;
	}

	.header-contacts .social-links a {
		width: 28px;
	}
}

/* Narrow tablet: only the socials fit next to the CTA button. */
@media (min-width: 768px) and (max-width: 899px) {
	.header-contacts .social-links__contact {
		display: none;
	}
}

/* Small laptops: compact sizing so the logo isn't squeezed. */
@media (min-width: 992px) and (max-width: 1279px) {
	.header .centered-menu-wrap .main-nav {
		gap: 12px;
	}

	.header .centered-menu-wrap .main-nav > #menu-top-left-menu > li > a {
		padding-left: 6px;
		padding-right: 6px;
	}

	.header .centered-menu-wrap .main-nav .accent-navigation li a {
		font-size: 14px;
	}

	.header-contacts .social-links a {
		width: 28px;
	}
}

/* Large screens: header.css bumps the menu to 18px here. */
@media (min-width: 1576px) {
	.header .centered-menu-wrap .main-nav > #menu-top-left-menu > li > a {
		padding-left: 8px;
		padding-right: 8px;
	}
}

/* Mobile menu: phone and email as text, icons for socials only. */
@media (max-width: 767px) {
	.header-contacts {
		flex-direction: column;
		align-items: flex-start;
		gap: 16px;
		padding: 20px 0;
	}

	.header-contacts .contact-links {
		display: flex;
	}

	.header-contacts .social-links__contact {
		display: none;
	}

	.header-contacts .contact-links a {
		font-size: 14px;
	}
}
