/*
 * Login Page IP Card — everything is scoped under .oe_login_form .o_ipcard.
 * The card sits inside the login form, where website themes style buttons,
 * selects and inputs; the extra specificity / !important on the visual
 * properties keeps those theme rules from leaking into the widget.
 */

.oe_login_form .o_ipcard {
    position: relative;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    text-align: left;
}

.oe_login_form .o_ipcard_frame {
    position: relative;
    opacity: 0;
    transition: opacity .35s ease;
}
.oe_login_form .o_ipcard.is-ready .o_ipcard_frame {
    opacity: 1;
}

.oe_login_form .o_ipcard_media {
    line-height: 0;
    transition: opacity .15s linear;
}
.oe_login_form .o_ipcard_img {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    -webkit-user-select: none;
    user-select: none;
}

/* ---- toggle ------------------------------------------------------------
 * The arrow is the button's own background image (no child element, no
 * currentColor), so theme rules for button text, spans or pseudo-elements
 * cannot hide it.
 */

.oe_login_form .o_ipcard .o_ipcard_toggle {
    position: absolute !important;
    top: 6px;
    right: 6px;
    z-index: 2;
    display: block !important;
    box-sizing: border-box !important;
    width: 22px !important;
    height: 22px !important;
    min-width: 0 !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 50% !important;
    background: rgba(32, 33, 36, .55) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5 6 7.5 9 4.5' fill='none' stroke='%23ffffff' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat center center / 12px 12px !important;
    box-shadow: none !important;
    font-size: 0 !important;
    color: transparent !important;
    text-indent: -9999px;
    overflow: hidden;
    cursor: pointer;
    opacity: 0;
    transition: opacity .2s ease, background-color .2s ease;
}
.oe_login_form .o_ipcard button::before,
.oe_login_form .o_ipcard button::after {
    content: none !important;
    display: none !important;
}
.oe_login_form .o_ipcard:hover .o_ipcard_toggle,
.oe_login_form .o_ipcard.is-open .o_ipcard_toggle,
.oe_login_form .o_ipcard .o_ipcard_toggle:focus {
    opacity: 1;
}
.oe_login_form .o_ipcard .o_ipcard_toggle:hover {
    background-color: rgba(32, 33, 36, .75) !important;
}
.oe_login_form .o_ipcard.is-open .o_ipcard_toggle {
    background: rgba(32, 33, 36, .75) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M3 7.5 6 4.5 9 7.5' fill='none' stroke='%23ffffff' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat center center / 12px 12px !important;
}
.oe_login_form .o_ipcard .o_ipcard_toggle:focus {
    outline: none;
}
.oe_login_form .o_ipcard .o_ipcard_toggle:focus-visible {
    box-shadow: 0 0 0 2px rgba(255, 255, 255, .7) !important;
}
/* Touch screens have no hover: tapping the card reveals the arrow (is-peek, set by JS). */
.oe_login_form .o_ipcard.is-peek .o_ipcard_toggle {
    opacity: 1;
}

/* ---- menu: dark grey, translucent ------------------------------------- */

.oe_login_form .o_ipcard .o_ipcard_menu {
    position: absolute;
    top: 34px;
    right: 6px;
    z-index: 3;
    box-sizing: border-box;
    width: 230px;
    max-width: calc(100% - 12px);
    padding: 10px 10px 8px;
    font-size: 12px;
    line-height: 1.4;
    color: #e8eaed;
    background: rgba(32, 33, 36, .82);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, .1);
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .25);
}
.oe_login_form .o_ipcard .o_ipcard_menu[hidden] {
    display: none;
}
.oe_login_form .o_ipcard .o_ipcard_field {
    display: block;
    margin: 0 0 8px;
    font-size: 12px;
    font-weight: normal;
}
.oe_login_form .o_ipcard .o_ipcard_label {
    display: flex;
    justify-content: space-between;
    margin-bottom: 3px;
    color: rgba(232, 234, 237, .65);
}
.oe_login_form .o_ipcard .o_ipcard_opacity_value {
    color: #e8eaed;
    font-variant-numeric: tabular-nums;
}
.oe_login_form .o_ipcard .o_ipcard_field select {
    display: block;
    box-sizing: border-box;
    width: 100% !important;
    height: 28px !important;
    margin: 0 !important;
    padding: 2px 24px 2px 8px !important;
    font-size: 12px !important;
    line-height: 22px;
    color: #fff !important;
    background-color: rgba(255, 255, 255, .08) !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 10 10'%3E%3Cpath d='M2 3.5 5 6.5 8 3.5' fill='none' stroke='%23e8eaed' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 8px center !important;
    border: 1px solid rgba(255, 255, 255, .16) !important;
    border-radius: 5px !important;
    box-shadow: none !important;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    cursor: pointer;
}
.oe_login_form .o_ipcard .o_ipcard_field select:focus {
    outline: none;
    border-color: rgba(255, 255, 255, .4) !important;
}
.oe_login_form .o_ipcard .o_ipcard_field option {
    color: #e8eaed;
    background: #2b2c2f;
}

/* opacity slider */
.oe_login_form .o_ipcard .o_ipcard_field input[type="range"] {
    display: block;
    box-sizing: border-box;
    width: 100% !important;
    height: 16px !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}
.oe_login_form .o_ipcard .o_ipcard_field input[type="range"]:focus {
    outline: none;
}
.oe_login_form .o_ipcard .o_ipcard_field input[type="range"]::-webkit-slider-runnable-track {
    height: 4px;
    background: rgba(255, 255, 255, .22);
    border-radius: 2px;
}
.oe_login_form .o_ipcard .o_ipcard_field input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    margin-top: -4px;
    background: #fff;
    border: 0;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .4);
}
.oe_login_form .o_ipcard .o_ipcard_field input[type="range"]::-moz-range-track {
    height: 4px;
    background: rgba(255, 255, 255, .22);
    border: 0;
    border-radius: 2px;
}
.oe_login_form .o_ipcard .o_ipcard_field input[type="range"]::-moz-range-thumb {
    width: 12px;
    height: 12px;
    background: #fff;
    border: 0;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .4);
}

/* Reset / Hide row */
.oe_login_form .o_ipcard .o_ipcard_actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 4px 10px;
    margin-top: 2px;
    padding-top: 7px;
    border-top: 1px solid rgba(255, 255, 255, .1);
}
.oe_login_form .o_ipcard .o_ipcard_actions button {
    display: inline-block !important;
    width: auto !important;
    height: auto !important;
    min-width: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    font-size: 12px !important;
    font-weight: normal !important;
    line-height: 1.4 !important;
    color: rgba(232, 234, 237, .75) !important;
    background: none !important;
    border: 0 !important;
    box-shadow: none !important;
    text-transform: none !important;
    cursor: pointer;
}
.oe_login_form .o_ipcard .o_ipcard_actions button:hover {
    color: #fff !important;
    text-decoration: underline;
}

/* ---- slim layouts: centre the arrow, open the menu below the strip ----- */

.oe_login_form .o_ipcard[data-layout="badge"] .o_ipcard_toggle {
    top: 50%;
    margin-top: -11px !important;
}
.oe_login_form .o_ipcard[data-layout="badge"] .o_ipcard_menu,
.oe_login_form .o_ipcard[data-layout="bar"] .o_ipcard_menu {
    top: calc(100% + 6px);
}
