/* Global admin typography */
:root {
  --custom-ui-font: 'Bricolage Grotesque', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
}

body.wp-admin,
#wpcontent,
#wpbody,
#wpbody-content,
.wrap,
.wp-core-ui,
.wp-list-table,
.widefat,
.notice,
.description,
.updated,
.error {
  font-family: var(--custom-ui-font) !important;
  letter-spacing: 0.01em;
}

.wp-core-ui .button,
.wp-core-ui .button-primary,
.wp-core-ui .button-secondary,
input,
select,
textarea,
button,
label,
.form-table th,
.form-table td,
.page-title-action,
.components-button,
.tablenav .tablenav-pages,
.subsubsub a,
.wp-heading-inline,
h1,
h2,
h3,
h4,
h5,
h6,
p,
li,
a {
  font-family: var(--custom-ui-font) !important;
}

/* Frontend adjustments */
form.woocommerce-checkout .checkout-inline-error-message,
.elementor-widget-woocommerce-checkout form.woocommerce-checkout .checkout-inline-error-message,
.woocommerce-MyAccount-content form .checkout-inline-error-message {
  display: none !important;
}

#account_first_name,
#account_last_name,
#account_display_name {
  display: none !important;
}

.woocommerce-account .woocommerce-order .woocommerce-order-downloads,
.woocommerce-account .woocommerce-order .order-again,
.woocommerce-account .woocommerce-order .woocommerce-customer-details .woocommerce-column--billing-address {
  display: none !important;
}

.woocommerce-account .custom-ui-account-details-title {
  margin-bottom: 24px;
}

/* Admin profile cleanup */
body.user-edit-php .user-rich-editing-wrap,
body.profile-php .user-rich-editing-wrap,
body.user-edit-php .user-admin-color-wrap,
body.profile-php .user-admin-color-wrap,
body.user-edit-php .show-admin-bar,
body.profile-php .show-admin-bar,
body.user-edit-php .user-language-wrap,
body.profile-php .user-language-wrap,
body.user-edit-php .user-comment-shortcuts-wrap,
body.profile-php .user-comment-shortcuts-wrap,
body.user-edit-php .user-profile-picture,
body.profile-php .user-profile-picture,
body.user-edit-php tr.user-profile-picture,
body.profile-php tr.user-profile-picture,
body.user-edit-php .user-description-wrap,
body.profile-php .user-description-wrap,
body.user-edit-php tr.user-description-wrap,
body.profile-php tr.user-description-wrap,
body.user-edit-php #description,
body.profile-php #description,
body.user-edit-php #application-passwords-section,
body.profile-php #application-passwords-section,
body.user-edit-php .user-url-wrap,
body.profile-php .user-url-wrap,
body.user-edit-php #url,
body.profile-php #url,
body.user-edit-php #woocommerce-customer-meta-fields .wc-customer-shipping,
body.profile-php #woocommerce-customer-meta-fields .wc-customer-shipping,
body.user-edit-php .wc-customer-shipping,
body.profile-php .wc-customer-shipping,
body.user-edit-php #wpseo_profile_settings,
body.profile-php #wpseo_profile_settings,
body.user-edit-php .yoast-profile-page,
body.profile-php .yoast-profile-page,
body.user-edit-php .yoast-settings,
body.profile-php .yoast-settings,
body.user-edit-php #yoast-settings,
body.profile-php #yoast-settings,
body.user-edit-php .wpseo-admin-page,
body.profile-php .wpseo-admin-page,
body.user-edit-php .elementor-ai-section,
body.profile-php .elementor-ai-section,
body.user-edit-php .elementor-notes-section,
body.profile-php .elementor-notes-section,
body.user-edit-php h2.vt-hide-contact-info-heading,
body.profile-php h2.vt-hide-contact-info-heading,
body.user-edit-php #woocommerce-customer-meta-fields .form-field-billing_company,
body.profile-php #woocommerce-customer-meta-fields .form-field-billing_company,
body.user-edit-php #woocommerce-customer-meta-fields .form-field-billing_address_1,
body.profile-php #woocommerce-customer-meta-fields .form-field-billing_address_1,
body.user-edit-php #woocommerce-customer-meta-fields .form-field-billing_address_2,
body.profile-php #woocommerce-customer-meta-fields .form-field-billing_address_2,
body.user-edit-php #woocommerce-customer-meta-fields .form-field-billing_city,
body.profile-php #woocommerce-customer-meta-fields .form-field-billing_city,
body.user-edit-php #woocommerce-customer-meta-fields .form-field-billing_postcode,
body.profile-php #woocommerce-customer-meta-fields .form-field-billing_postcode,
body.user-edit-php tr.user-nickname-wrap,
body.profile-php tr.user-nickname-wrap,
body.user-edit-php .user-nickname-wrap,
body.profile-php .user-nickname-wrap,
body.user-edit-php #nickname,
body.profile-php #nickname {
  display: none !important;
}

body.user-edit-php #your-profile h2,
body.profile-php #your-profile h2,
body.user-edit-php #your-profile h3,
body.profile-php #your-profile h3,
body.user-edit-php #woocommerce-customer-meta-fields h2,
body.profile-php #woocommerce-customer-meta-fields h2 {
  font-size: 18px !important;
}

body.user-edit-php .wrap h1.wp-heading-inline,
body.profile-php .wrap h1.wp-heading-inline {
  font-size: 15px !important;
  font-weight: 600 !important;
  margin-top: 24px !important;
  display: flex;
  gap: 6px;
  align-items: baseline;
}

body.user-edit-php .wrap h1.wp-heading-inline .custom-ui-heading-prefix,
body.profile-php .wrap h1.wp-heading-inline .custom-ui-heading-prefix {
  font-size: 15px !important;
  font-weight: 600 !important;
}

body.user-edit-php .wrap h1.wp-heading-inline .custom-ui-heading-name,
body.profile-php .wrap h1.wp-heading-inline .custom-ui-heading-name {
  font-size: 18px !important;
  font-weight: 600 !important;
}

body.user-edit-php tr.user-user-login-wrap .description,
body.profile-php tr.user-user-login-wrap .description {
  display: block;
  margin-top: 4px;
}

body.user-edit-php #woocommerce-customer-meta-fields .form-field-billing_state .description,
body.profile-php #woocommerce-customer-meta-fields .form-field-billing_state .description {
  display: none !important;
}

body.user-edit-php .wrap .page-title-action,
body.profile-php .wrap .page-title-action {
  display: none !important;
}

body.user-edit-php #first_name:disabled,
body.profile-php #first_name:disabled,
body.user-edit-php #last_name:disabled,
body.profile-php #last_name:disabled,
body.user-edit-php #display_name:disabled,
body.profile-php #display_name:disabled {
  background-color: #f6f7f7 !important;
  cursor: not-allowed !important;
  opacity: 0.9;
}

.flatpickr-input,
.flatpickr-input[readonly] {
  background-color: #fff !important;
  color: inherit !important;
}

/* Admin orders layout */
body.post-type-shop_order #order_data .order_data_column .address,
body[class*="wc-orders"] #order_data .order_data_column .address {
  display: none !important;
}

body.post-type-shop_order #order_data .order_data_column .vt-user-profile-snapshot,
body[class*="wc-orders"] #order_data .order_data_column .vt-user-profile-snapshot {
  display: block !important;
}