﻿/* =========================
   myPassword control
========================= */

/* Host custom element */
mypassword {
    display: block;
    width: 100%;
    box-sizing: border-box;
}

/* Élément réel : input en édition, div en readonly */
.myPassword {
    box-sizing: border-box;
    width: 100%;
    height: var(--zen-ctrl-height);
    min-height: var(--zen-ctrl-height);
    padding: 0 var(--zen-ctrl-padding-x);
    border-top: none;
    border-left: none;
    border-right: none;
    border-bottom: 1px solid var(--zen-ctrl-border-color);
    border-radius: 0;
    background: transparent;
    color: #1f2937;
    font-family: var(--zen-ctrl-font-family);
    font-size: var(--zen-ctrl-font-size);
    line-height: normal;
    outline: none;
}

/* Mode édition */
input.myPassword {
    display: block;
}

/* Mode readonly */
div.myPassword,
.myPassword.is-readonly {
    display: flex;
    align-items: center;
    cursor: default;
    border-bottom:none
}

/* Placeholder HTML input */
input.myPassword::placeholder {
    color: #9ca3af;
}

/* Placeholder custom readonly */
.myPassword.is-placeholder {
    color: #9ca3af;
}

/* Disabled / readonly */
input.myPassword:disabled,
.myPassword.is-readonly {
    color: var(--zen-ctrl-disabled-color);
    background: transparent;
    opacity: 1;
}

/* Focus */
input.myPassword:focus {
    border-bottom-color: #0F6CB7;
}
