/*
 Theme Name: Divi Child Commons
 Description: Child theme for the Commons root site.
 Template: Divi
 Version: 1.0
*/
/* =========================================================
   GLOBAL SITE STYLES
   ========================================================= */


/* LINK HOVER
--------------------------------------------------------- */

a:hover,
a:focus {
    color: #168c7e;
}

/* =========================================================
   NETWORK SIGNUP PAGE
   ========================================================= */


/* PAGE
--------------------------------------------------------- */

body.bgc-signup-page {
    background: #ffffff;
    margin: 0;
    padding: 0;
}


/* SIGNUP HEADER
--------------------------------------------------------- */

.bgc-signup-header {
    width: 100%;
    background: #ffffff;
    border-bottom: 1px solid #d9d9d9;
}

.bgc-signup-header-inner {
    width: 80%;
    max-width: 1080px;
    margin: 0 auto;
    padding: 22px 0;
    box-sizing: border-box;
}

.bgc-signup-logo {
    display: block;
    text-decoration: none;
}

.bgc-signup-logo img {
    display: block;
    width: auto;
    max-width: 100%;
    height: 53px;
    margin: 0 0 0 4px;
}


/* SIGNUP FORM CONTAINER
--------------------------------------------------------- */

.mu_register {
    width: calc(100% - 60px);
    max-width: 900px;
    margin: 24px auto 50px;
    padding: 0;
    box-sizing: border-box;
}


/* TYPOGRAPHY
--------------------------------------------------------- */

.mu_register h2 {
    font-size: 32px;
    line-height: 1.2;
    margin-top: 0;
    margin-bottom: 24px;
}

/* Remove WordPress emphasis styling from signup heading */
body.bgc-signup-page .mu_register h2 em {
    font-style: normal;
}

.mu_register p {
    font-size: 16px;
    line-height: 1.6;
}


/* LINKS
--------------------------------------------------------- */

body.bgc-signup-page .mu_register a {
    color: #20bca8;
    text-decoration: none;
}

body.bgc-signup-page .mu_register a:hover,
body.bgc-signup-page .mu_register a:focus {
    color: #168c7e;
    text-decoration: underline;
}


/* FORM LABELS
--------------------------------------------------------- */

body.bgc-signup-page .mu_register label,
body.bgc-signup-page .mu_register legend,
body.bgc-signup-page .mu_register .label-heading {
    display: block;
    margin-top: 20px;
    margin-bottom: 4px;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.3;
}


/* FORM FIELDS
--------------------------------------------------------- */

body.bgc-signup-page .mu_register input[type="text"],
body.bgc-signup-page .mu_register input[type="email"],
body.bgc-signup-page .mu_register #blog_title,
body.bgc-signup-page .mu_register #user_email,
body.bgc-signup-page .mu_register #blogname,
body.bgc-signup-page .mu_register #user_name {
    width: 100%;
    max-width: 550px;
    padding: 6px 10px;
    margin: 6px 0 10px;
    box-sizing: border-box;
    font-size: 16px;
    line-height: 1.4;
    background: #ffffff;
    color: #222222;
    border: 1px solid #aaaaaa;
    border-radius: 2px;
}


/* SITE DOMAIN FIELD
--------------------------------------------------------- */

body.bgc-signup-page .mu_register #blogname {
    display: inline-block;
    width: 360px;
    max-width: calc(100% - 230px);
    padding: 6px 10px !important;
    vertical-align: bottom;
}

body.bgc-signup-page .mu_register .suffix_address {
    display: inline-block;
    margin-left: 6px;
    padding-bottom: 6px;
    vertical-align: bottom;
    font-size: 16px !important;
    line-height: 1.4;
}


/* SITE DOMAIN HELPER TEXT
--------------------------------------------------------- */

body.bgc-signup-page .mu_register .bgc-domain-help {
    display: block !important;
    width: 100%;
    margin: 4px 0 32px !important;
    font-size: 16px !important;
    line-height: 1.4;
    color: #666666;
}


/* PRIVACY
--------------------------------------------------------- */

body.bgc-signup-page .mu_register .privacy-intro {
    margin-top: 32px;
}

body.bgc-signup-page .mu_register .privacy-intro legend,
body.bgc-signup-page .mu_register .privacy-intro .label-heading {
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.3;
}

body.bgc-signup-page .mu_register .privacy-intro p {
    margin: 0 0 10px;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.5;
}

body.bgc-signup-page .mu_register .privacy-intro .wp-signup-radio-button,
body.bgc-signup-page .mu_register .signup-options .wp-signup-radio-button {
    display: flex;
    align-items: center;
    gap: 7px;
    margin: 7px 0;
    padding: 0;
}

body.bgc-signup-page .mu_register .privacy-intro label,
body.bgc-signup-page .mu_register .signup-options label,
body.bgc-signup-page .mu_register label.checkbox {
    display: inline !important;
    margin: 0 !important;
    padding: 0;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.4;
}

body.bgc-signup-page .mu_register .privacy-intro input[type="radio"],
body.bgc-signup-page .mu_register .signup-options input[type="radio"] {
    flex: 0 0 auto;
    width: auto;
    height: auto;
    margin: 0 !important;
    padding: 0;
    vertical-align: middle;
}

/* PRIVACY GROUP DIVIDER
--------------------------------------------------------- */

body.bgc-signup-page .mu_register p.wp-signup-radio-buttons::after {
    content: "";
    display: block;
    width: 180px;
    height: 1px;
    margin: 18px 0 16px;
    background: #d9d9d9;
}


/* CREATE SITE BUTTON
--------------------------------------------------------- */

body.bgc-signup-page .mu_register input[type="submit"] {
    display: inline-block;
    width: auto !important;
    min-width: 180px;
    margin-top: 24px;
    padding: 16px 32px;
    background: #20bca8;
    color: #ffffff;
    border: 0;
    border-radius: 3px;
    font-size: 19px;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    transition:
        background-color 0.2s ease,
        transform 0.1s ease;
}

body.bgc-signup-page .mu_register input[type="submit"]:hover,
body.bgc-signup-page .mu_register input[type="submit"]:focus {
    background: #168c7e;
}

body.bgc-signup-page .mu_register input[type="submit"]:active {
    transform: translateY(1px);
}


/* ERROR MESSAGES
--------------------------------------------------------- */

.mu_register .error {
    padding: 12px 14px;
    margin: 15px 0;
    color: #333333;
    background: #ffebe8;
    border: 1px solid #cc0000;
}


/* WORDPRESS MULTISITE ALERTS
--------------------------------------------------------- */

.mu_register .mu_alert {
    padding: 12px 14px;
    margin: 15px 0;
    font-weight: 600;
    color: #333333;
    background: #ffffe0;
    border: 1px solid #e6db55;
}

.mu_register .mu_alert a {
    color: inherit;
    text-decoration: underline;
}


/* =========================================================
   BUDDYPRESS MEMBER / PROFILE PAGES
   ========================================================= */


/* HIDE FOOTER
--------------------------------------------------------- */

body.buddypress #main-footer {
    display: none !important;
}


/* BOTTOM PAGE SPACING
--------------------------------------------------------- */

body.buddypress #main-content {
    padding-bottom: 50px;
}


/* REMOVE DIVI SIDEBAR
--------------------------------------------------------- */

body.buddypress #sidebar {
    display: none !important;
}

body.buddypress #left-area {
    width: 100% !important;
    float: none !important;
    padding-right: 0 !important;
}

body.buddypress #main-content .container::before {
    display: none !important;
}

body.buddypress #content-area {
    width: 100%;
}

body.buddypress #buddypress {
    width: 100%;
    max-width: 1100px;
}


/* HIDE UNUSED MEMBER NAV ITEMS
--------------------------------------------------------- */

body.buddypress #object-nav #forums-personal-li,
body.buddypress #object-nav #docs-personal-li,
body.buddypress #object-nav #invite-anyone-personal-li {
    display: none !important;
}


/* PROFILE PHOTO
--------------------------------------------------------- */

body.buddypress #item-header-avatar img.avatar {
    border: 3px solid #8edfd4;
    padding: 3px;
    background: #ffffff;
}


/* HIDE MEMBER LAST-ACTIVE TIME
--------------------------------------------------------- */

body.buddypress #item-header-content .activity {
    display: none !important;
}


/* PRIMARY MEMBER NAV
   Profile / Settings
--------------------------------------------------------- */

body.buddypress #item-nav {
    margin: 22px 0 28px;
}

body.buddypress #object-nav > ul {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none;
    border-bottom: 1px solid #d9d9d9;
}

body.buddypress #object-nav > ul > li {
    float: none !important;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none;
}

body.buddypress #object-nav > ul > li > a {
    display: block;
    padding: 11px 16px;
    font-size: 16px;
    font-weight: 500;
    line-height: 1.2;
    color: #555555 !important;
    background: transparent !important;
    text-decoration: none !important;
    border: none !important;
    transition:
        color 0.2s ease,
        background-color 0.2s ease;
}

body.buddypress #object-nav > ul > li > a:hover,
body.buddypress #object-nav > ul > li > a:focus {
    color: #168c7e !important;
    background: #f5f5f5 !important;
}

body.buddypress #object-nav > ul > li.current > a,
body.buddypress #object-nav > ul > li.selected > a {
    color: #222222 !important;
    background: #ffffff !important;
    font-weight: 600;
    border-bottom: 3px solid #20bca8 !important;
}


/* SECONDARY MEMBER NAV
   View / Edit / Change Profile Photo
--------------------------------------------------------- */

body.buddypress #item-body #subnav {
    margin-top: -18px !important;
    margin-bottom: 34px !important;
}

body.buddypress #item-body #subnav > ul {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none;
}

body.buddypress #item-body #subnav > ul > li {
    float: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

body.buddypress #item-body #subnav > ul > li > a {
    display: block;
    padding: 7px 12px;
    color: #168c7e !important;
    background: transparent !important;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.2;
    text-decoration: none !important;
    border: 1px solid transparent;
    border-radius: 3px;
    transition:
        color 0.2s ease,
        background-color 0.2s ease,
        border-color 0.2s ease;
}

body.buddypress #item-body #subnav > ul > li > a:hover,
body.buddypress #item-body #subnav > ul > li > a:focus {
    color: #222222 !important;
    background: #f3f3f3 !important;
    border-color: #dddddd;
}

body.buddypress #item-body #subnav > ul > li.current > a,
body.buddypress #item-body #subnav > ul > li.selected > a {
    color: #222222 !important;
    background: #eeeeee !important;
    font-weight: 600;
    border-color: #d5d5d5;
}

/* PROFILE EDIT FORM SPACING
--------------------------------------------------------- */

/* Separate each field from the previous field's visibility text */
body.buddypress #profile-edit-form .editfield {
    margin-top: 24px !important;
}

/* Keep labels close to their fields */
body.buddypress #profile-edit-form .editfield > label {
    margin-bottom: 6px !important;
}

/*
 * Rich-text editors receive excessive vertical spacing from
 * the BuddyPress/WordPress editor layout. This is the final
 * working adjustment for Academic Interests and About You.
 */
body.buddypress #profile-edit-form .wp-editor-wrap {
    position: relative;
    top: -42px;
    margin-top: 6px !important;
    margin-bottom: -42px !important;
}

/* PROFILE FIELD GROUP TABS
--------------------------------------------------------- */

body.buddypress #profile-edit-form .button-nav {
    margin-left: 0 !important;
    padding-left: 0 !important;
}

body.buddypress #profile-edit-form .button-nav li:first-child {
    margin-left: 0 !important;
}


/* PROFILE FIELD VISIBILITY
--------------------------------------------------------- */

/* All profile field visibility messages */
body.buddypress #profile-edit-form .field-visibility-settings-toggle,
body.buddypress #profile-edit-form .field-visibility-settings-notoggle {
    margin-top: 5px !important;
    margin-bottom: 0 !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
    color: #777777;
}

body.buddypress #profile-edit-form .field-visibility-settings-toggle *,
body.buddypress #profile-edit-form .field-visibility-settings-notoggle * {
    font-size: inherit !important;
    line-height: inherit !important;
}
body.buddypress #profile-edit-form .field-visibility-settings {
    margin-top: 5px !important;
    margin-bottom: 0 !important;
}


/* Change visibility control */
body.buddypress #profile-edit-form .field-visibility-settings-toggle .visibility-toggle-link,
body.buddypress #profile-edit-form .field-visibility-settings-toggle a {
    display: inline-block;
    margin-left: 6px;
    padding: 3px 8px;
    font-size: 14px !important;
    font-weight: 600;
    color: #168c7e !important;
    background: #f4f4f4;
    border: 1px solid #cccccc;
    border-radius: 3px;
    text-decoration: none !important;
}

body.buddypress #profile-edit-form .field-visibility-settings-toggle .visibility-toggle-link:hover,
body.buddypress #profile-edit-form .field-visibility-settings-toggle .visibility-toggle-link:focus,
body.buddypress #profile-edit-form .field-visibility-settings-toggle a:hover,
body.buddypress #profile-edit-form .field-visibility-settings-toggle a:focus {
    color: #222222 !important;
    background: #eeeeee;
    border-color: #aaaaaa;
}


/* PROFILE SAVE BUTTON
--------------------------------------------------------- */

body.buddypress #profile-edit-form input[type="submit"] {
    display: inline-block;
    padding: 10px 20px;
    background: #20bca8 !important;
    color: #ffffff !important;
    border: none !important;
    border-radius: 3px;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
}

body.buddypress #profile-edit-form input[type="submit"]:hover,
body.buddypress #profile-edit-form input[type="submit"]:focus {
    background: #168c7e !important;
    color: #ffffff !important;
}


/* MEMBER SETTINGS PASSWORD FIELDS
--------------------------------------------------------- */

body.buddypress #settings-form input[type="password"] {
    width: 100% !important;
    max-width: 500px !important;
    box-sizing: border-box;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media screen and (max-width: 700px) {

    .bgc-signup-header-inner {
        padding: 8px 20px;
    }

    .bgc-signup-logo img {
        width: auto;
        max-width: 100%;
        height: auto;
    }

    .mu_register {
        width: calc(100% - 40px);
        margin: 30px auto;
    }

    .mu_register h2 {
        font-size: 26px;
    }

    body.bgc-signup-page .mu_register #blogname {
        width: 100%;
        max-width: 100%;
    }

    body.bgc-signup-page .mu_register .suffix_address {
        display: block;
        margin: 2px 0 0;
        padding-bottom: 0;
    }

    body.bgc-signup-page .mu_register input[type="text"],
    body.bgc-signup-page .mu_register input[type="email"],
    body.bgc-signup-page .mu_register #blog_title,
    body.bgc-signup-page .mu_register #user_email,
    body.bgc-signup-page .mu_register #user_name {
        max-width: 100%;
    }

    body.buddypress #object-nav > ul {
        gap: 0;
    }

    body.buddypress #object-nav > ul > li > a {
        padding: 10px 12px;
        font-size: 15px;
    }
}

/* =========================================================
   BUDDYPRESS CREATE SITE — PRIVACY OPTIONS
   ========================================================= */

/* Tighten the standard Yes / No options */
body.blogs.create-blog #buddypress .standard-form fieldset.create-site p {
    margin: 5px 0 !important;
    padding: 0 !important;
}

body.blogs.create-blog #buddypress .standard-form fieldset.create-site label.checkbox {
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    width: auto !important;
    font-size: 16px;
    line-height: 1.35;
}

/* Add a divider after the Yes / No group */
body.blogs.create-blog #buddypress .standard-form fieldset.create-site {
    margin-bottom: 14px;
    padding-bottom: 14px;
    border-bottom: 1px solid #d9d9d9;
}

/* Style the three additional privacy choices */
body.blogs.create-blog #buddypress .standard-form label.checkbox[for^="blog-private-"] {
    display: block !important;
    margin: 5px 0 !important;
    padding: 0 !important;
    width: auto !important;
    font-size: 16px;
    font-weight: 600 !important;
    line-height: 1.35;
}

/* Their <br> tags are unnecessary once labels are block-level */
body.blogs.create-blog #buddypress .standard-form label.checkbox[for^="blog-private-"] + br {
    display: none !important;
}

/* Keep all privacy radio buttons aligned */
body.blogs.create-blog #buddypress .standard-form label.checkbox input[type="radio"] {
    width: auto !important;
    height: auto !important;
    margin: 0 7px 0 0 !important;
    padding: 0 !important;
    vertical-align: middle;
}

/* Give the Create Site button a little breathing room */
body.blogs.create-blog #buddypress .standard-form #submit {
    margin-top: 16px !important;
}

/* Add breathing room before Site Domain */
body.blogs.create-blog #buddypress .standard-form label[for="blogname"] {
    margin-top: 12px !important;
}

/* =========================================================
   BUDDYPRESS MEMBER SITES — COMPACT GRID
   ========================================================= */

/* Turn the member Sites list into a responsive card grid */
body.buddypress #buddypress ul#blogs-list,
body.buddypress #buddypress ul.item-list#blogs-list {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin: 20px 0 0 !important;
    padding: 0 !important;
    list-style: none;
}

/* Individual site card */
body.buddypress #buddypress #blogs-list > li {
    position: relative;
    display: block;
    width: auto !important;
    min-height: 150px;
    margin: 0 !important;
    padding: 16px !important;
    background: #ffffff;
    border: 1px solid #dddddd;
    box-sizing: border-box;
}

/* Hide the generic site icon */
body.buddypress #buddypress #blogs-list > li .item-avatar {
    display: none !important;
}

/* Let the site information use the full card width */
body.buddypress #buddypress #blogs-list > li .item {
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Site title */
body.buddypress #buddypress #blogs-list > li h2.list-title.blogs-title {
    margin: 0 0 10px !important;
    padding: 0 !important;
    font-size: 17px !important;
    line-height: 1.25 !important;
}

/* Hide site activity / last-active information */
body.buddypress #buddypress #blogs-list > li .activity,
body.buddypress #buddypress #blogs-list > li .item-meta {
    display: none !important;
}

/* =========================================================
   COMMONS MY SITES — CARD CONTENT CLEANUP
   ========================================================= */

/* Hide ALL Latest Post information */
body.buddypress #buddypress #blogs-list .item-meta,
body.buddypress #buddypress #blogs-list .item-desc,
body.buddypress #buddypress #blogs-list .meta,
body.buddypress #buddypress #blogs-list .last-post {
    display: none !important;
}


/* Visit Site button area — align left */
body.buddypress #buddypress #blogs-list > li .action {
    position: static !important;
    float: none !important;
    clear: both !important;
    width: 100% !important;
    margin: 22px 0 0 !important;
    padding: 0 !important;
    text-align: left !important;
}

/* Larger Visit Site button */
body.buddypress #buddypress #blogs-list > li .action a,
body.buddypress #buddypress #blogs-list > li .action .button {
    display: inline-block !important;
    padding: 12px 22px !important;
    min-width: 120px;
    font-size: 16px !important;
    line-height: 1.2 !important;
    text-align: center;
}


/* =========================================================
   MEMBER SITES — RESPONSIVE GRID
   ========================================================= */

@media screen and (max-width: 1100px) {
    body.buddypress #buddypress ul#blogs-list,
    body.buddypress #buddypress ul.item-list#blogs-list {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media screen and (max-width: 800px) {
    body.buddypress #buddypress ul#blogs-list,
    body.buddypress #buddypress ul.item-list#blogs-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media screen and (max-width: 600px) {
    body.buddypress #buddypress ul#blogs-list,
    body.buddypress #buddypress ul.item-list#blogs-list {
        grid-template-columns: 1fr;
    }
}
