/* Client area: the login page's "Request access" form, and the overview and documents inside
   WooCommerce's My Account content. Lines, colours and type follow the account page styles in
   the child theme (#f0f0f0 rules, black titles on the site's 14px text). "#page-container"
   outweighs Divi's "#left-area ul" list styles without !important. */

/* Login page: log in | request access. The request form takes WooCommerce's own form box
   (class "register") and field styles; only what WooCommerce doesn't style is set here. */

.jero-ca-login {
	display: grid;
	gap: 40px 64px;
}

.jero-ca-login__col {
	min-inline-size: 0;
}

@media (min-width: 981px) {
	.jero-ca-login {
		grid-template-columns: 1fr 1fr;
		align-items: start;
	}
}

/* The site styles text inputs grey and borderless (Divi's WooCommerce field styles), but not
   selects or textareas: same look here. The ID outweighs ".woocommerce form .form-row select". */
#page-container .jero-ca-request select,
#page-container .jero-ca-request textarea {
	inline-size: 100%;
	padding: 16px;
	border: 0;
	border-radius: 0;
	background-color: #eee;
	color: #999;
	font-size: 14px;
}

#page-container .jero-ca-request select {
	block-size: 56px;
	padding-block: 0;
	cursor: pointer;
}

.jero-ca-request__consent input {
	cursor: pointer;
}

.jero-ca-request__consent a {
	text-decoration: underline;
}

.jero-ca-error {
	display: block;
	color: #a00;
	font-size: 13px;
}

.jero-ca-error:empty {
	display: none;
}

.jero-ca-request [aria-invalid="true"] {
	outline: 1px solid #a00;
}

/* Honeypot: off screen for people, still a normal field for bots. */
.jero-ca-hp {
	position: absolute;
	inline-size: 1px;
	block-size: 1px;
	overflow: hidden;
	clip-path: inset(50%);
}

.jero-ca-hello {
	font-size: 18px;
	color: #000;
}

.jero-ca-heading {
	margin-block-start: 40px;
	padding-block-end: 16px;
	border-block-end: 1px solid #f0f0f0;
	font-size: 20px;
	color: #000;
}

/* Divi removes the bottom padding of a block's last paragraph, hence margins here. */
.jero-ca-hello + .woocommerce-info {
	margin-block-start: 16px;
}

/* Room before the footer on every account page: Divi gives full-width pages no bottom padding,
   so the last line (documents, the account details form's button) touched the footer. */
.woocommerce-account .woocommerce-MyAccount-content {
	padding-block-end: 40px;
}

/* The same for the "Lost your password?" and "choose a password" forms (logged-out pages). */
.woocommerce-account .lost_reset_password {
	margin-block-end: 40px;
}

.jero-ca-empty {
	padding-block-start: 20px;
}

/* Documents */

#page-container .jero-ca-docs,
#page-container .jero-ca-manager__contacts {
	margin: 0;
	padding: 0;
	list-style: none;
}

.jero-ca-doc {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 16px 32px;
	padding-block: 20px;
	border-block-end: 1px solid #f0f0f0;
}

.jero-ca-doc__text {
	flex: 1 1 260px;
	min-inline-size: 0;
}

.jero-ca-doc__title,
.jero-ca-doc__desc,
.jero-ca-doc__meta {
	display: block;
}

.jero-ca-doc__title {
	font-size: 16px;
	color: #000;
}

.jero-ca-doc__meta {
	font-size: 13px;
	color: #666;
}

.jero-ca-doc__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 20px;
}

#page-container .jero-ca-doc__download,
#page-container .jero-ca-more .button {
	display: inline-flex;
	align-items: center;
	min-block-size: 44px;
	cursor: pointer;
}

.jero-ca-doc__others a {
	display: inline-block;
	margin-inline-start: 8px;
	padding-block: 10px;
	text-decoration: underline;
}

.jero-ca-more {
	padding-block-start: 24px;
}

/* The site's buttons drop their outline on focus: the ID brings it back for these. */
#page-container .jero-ca-doc a:focus-visible,
#page-container .jero-ca-more a:focus-visible,
#page-container .jero-ca-manager a:focus-visible {
	outline: 2px solid #000;
	outline-offset: 2px;
}

/* Account manager */

.jero-ca-manager__card {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	gap: 20px 32px;
	padding-block: 20px;
	border-block-end: 1px solid #f0f0f0;
}

.jero-ca-manager__photo {
	inline-size: 96px;
	block-size: 96px;
	object-fit: cover;
}

.jero-ca-manager__name,
.jero-ca-manager__role {
	display: block;
}

.jero-ca-manager__name {
	font-size: 16px;
	color: #000;
}

.jero-ca-manager__label {
	display: inline-block;
	min-inline-size: 80px;
	color: #666;
}

.jero-ca-manager__contacts a {
	display: inline-block;
	padding-block: 10px;
	text-decoration: underline;
}
