﻿/* =========================================
   BUTTONS - BASE
   ========================================= */

input {
    width: 100%;
    /*display: block;*/
    padding: 5px 10px;
    border-radius: 6px;
    background-color: #fff;
    border: 1px solid #e3e3e3;
    margin-bottom: 5px;
}

    input:focus {
        box-shadow: 0 0 3px rgba(130,205,237,0.6);
    }

    input.input-approve {
        border: 1px solid #8ee070;
    }

    input.input-caution {
        border: 1px solid #ede45f;
    }

    input.input-error {
        border: 1px solid #ff4a4a;
    }

    input[type="checkbox"] {
        width: auto;
        float: left;
        margin-top: 5px;
        margin-right: 10px;
    }

        input[type="checkbox"] + label {
            padding-top: 1px;
            display: grid;
            white-space: normal;
        }

        input[type="checkbox"]:disabled + label {
            /*color: black;*/
            cursor: default;
        }

        input[type="checkbox"]:checked + label {
            color: black;
            font-weight: bold;
        }

        input[type="checkbox"] + span {
            /* <label><input type="checkbox" value="1" runat="server" /><span>Texte</span></label> */
        }

        input[type="checkbox"]:checked + span {
            color: black;
            font-weight: bold;
        }

a.button {
    color: rgba(0, 0, 0, 0.87);
}

    a.button:hover {
        color: rgba(26, 26, 26, 0.87);
    }

button,
.button {
    border-radius: 6px;
    margin-top: 5px;
    margin-bottom: 5px;
    padding: 9px 14px;
    display: inline-block;
    text-align: center;
    white-space: nowrap;
    vertical-align: middle;
    color: rgba(0, 0, 0, 0.87);
    background-color: #fff;
    border: 1px solid #d1d5db;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease, box-shadow 150ms ease, transform 100ms ease;
}

    button:hover,
    .button:hover {
        color: rgba(26, 26, 26, 0.87);
        background-color: #f8fafc;
        border-color: #cbd5e1;
        cursor: pointer;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.07);
    }

    button:active,
    .button:active {
        transform: translateY(1px);
        box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    }

    button a,
    .button a {
        color: rgba(0, 0, 0, 0.87);
    }

        button a:hover,
        .button a:hover {
            color: rgba(26, 26, 26, 0.87);
        }


/* =========================================
   PRIMARY - GRIS GRAPHITE
   ========================================= */

.button-primary {
    height: 42px;
    background-color: #52525b;
    border-color: #3f3f46;
    color: #fff;
    font-weight: 500;
}

    .button-primary:hover {
        color: #fff;
        background-color: #3f3f46;
        border-color: #27272a;
    }

    .button-primary a,
    .button-primary a:hover {
        color: #fff;
    }


/* =========================================
   INFO - BLEU
   ========================================= */

.button-info {
    height: 42px;
    background-color: #dbeafe;
    border-color: #2563eb;
    color: #1d4ed8;
    font-weight: 500;
}

    .button-info:hover {
        color: #1e40af;
        background-color: #bfdbfe;
        border-color: #1d4ed8;
    }

    .button-info a,
    .button-info a:hover {
        color: #1d4ed8;
    }


/* =========================================
   ACCENT - ROSE / ROUGE
   ========================================= */

.button-accent {
    height: 42px;
    background-color: #ffe4e6;
    border-color: #e11d48;
    color: #be123c;
    font-weight: 500;
}

    .button-accent:hover {
        color: #9f1239;
        background-color: #fecdd3;
        border-color: #be123c;
    }

    .button-accent a,
    .button-accent a:hover {
        color: #be123c;
    }


/* =========================================
   APPROVE - VERT
   ========================================= */

.button-approve {
    height: 42px;
    background-color: #dcfce7;
    border-color: #15803d;
    color: #166534;
    font-weight: 500;
}

    .button-approve:hover {
        color: #14532d;
        background-color: #bbf7d0;
        border-color: #166534;
    }

    .button-approve a,
    .button-approve a:hover {
        color: #166534;
    }


/* =========================================
   CAUTION - JAUNE / AMBRE
   ========================================= */

.button-caution {
    height: 42px;
    background-color: #fef3c7;
    border-color: #b45309;
    color: #92400e;
    font-weight: 500;
}

    .button-caution:hover {
        color: #78350f;
        background-color: #fde68a;
        border-color: #92400e;
    }

    .button-caution a,
    .button-caution a:hover {
        color: #92400e;
    }


/* =========================================
   ERROR - ROUGE
   ========================================= */

.button-error {
    height: 42px;
    background-color: #fee2e2;
    border-color: #dc2626;
    color: #b91c1c;
    font-weight: 500;
}

    .button-error:hover {
        color: #991b1b;
        background-color: #fecaca;
        border-color: #b91c1c;
    }

    .button-error a,
    .button-error a:hover {
        color: #b91c1c;
    }


/* =========================================
   LIGHT
   ========================================= */

.button-light {
    height: 42px;
    background-color: #f8fafc;
    border-color: #cbd5e1;
    color: #334155;
}

    .button-light:hover {
        color: #1e293b;
        background-color: #f1f5f9;
        border-color: #94a3b8;
    }

    .button-light a,
    .button-light a:hover {
        color: #334155;
    }


/* =========================================
   LIGHT SMALL
   ========================================= */

.button-light-small {
    width: 30px;
    color: rgba(0, 0, 0, 0.87);
    background-color: #fff;
    border-color: #d1d5db;
}

    .button-light-small:hover {
        color: #fff;
        background-color: #474747;
        border-color: #474747;
    }

    .button-light-small a,
    .button-light-small a:hover {
        color: rgba(0, 0, 0, 0.87);
    }


/* =========================================
   CHECK
   ========================================= */

.button-check {
    width: 30px;
    background-color: #52525b;
    border-color: #3f3f46;
    color: #fff;
    margin: 0;
}

    .button-check:hover {
        color: #fff;
        background-color: #3f3f46;
        border-color: #27272a;
    }


/* =========================================
   SIZES
   ========================================= */

.button-small {
    font-size: 85%;
    padding: 5px 10px;
}

.button-large {
    font-size: 115%;
    padding: 10px 20px;
}


/* =========================================
   IMAGE BUTTON
   ========================================= */

.imgagebutton {
    border: 1px solid #e3e3e3;
    border-radius: 7px;
    transition: border-color 150ms ease, transform 100ms ease, box-shadow 150ms ease;
    padding: 5px;
    cursor: pointer;
    height: 50px;
    background-color: transparent;
    max-width: 56px;
}

    .imgagebutton:hover {
        border-color: #94a3b8;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
    }

    .imgagebutton:active {
        transform: translateY(1px);
    }

.imagebutton-disabled {
    filter: grayscale(100%);
    opacity: 0.5;
    pointer-events: none;
    cursor: not-allowed;
}


/* =========================================
   DISABLED
   ========================================= */

button:disabled,
.button:disabled,
button:hover:disabled,
.button:hover:disabled,
.button-primary:disabled,
.button-primary:hover:disabled,
.button-info:disabled,
.button-info:hover:disabled,
.button-accent:disabled,
.button-accent:hover:disabled,
.button-approve:disabled,
.button-approve:hover:disabled,
.button-caution:disabled,
.button-caution:hover:disabled,
.button-error:disabled,
.button-error:hover:disabled,
.button-check:disabled,
.button-check:hover:disabled,
.button-light:disabled,
.button-light:hover:disabled,
.button-light-small:disabled,
.button-light-small:hover:disabled {
    color: #94a3b8;
    background-color: #f1f5f9;
    border-color: #d1d5db;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
    opacity: 0.75;
}


/* =========================================
   DARK MODE
   ========================================= */

@media (prefers-color-scheme: dark) {

    /* -----------------------------------------
       Base
       ----------------------------------------- */

    a.button {
        color: #e2e8f0;
    }

        a.button:hover {
            color: #f8fafc;
        }

    button,
    .button {
        color: #e2e8f0;
        background-color: #1e293b;
        border-color: #475569;
        box-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
    }

        button:hover,
        .button:hover {
            color: #f8fafc;
            background-color: #334155;
            border-color: #64748b;
            box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
        }

        button a,
        .button a {
            color: #e2e8f0;
        }

            button a:hover,
            .button a:hover {
                color: #f8fafc;
            }


    /* -----------------------------------------
       Primary - Graphite
       ----------------------------------------- */

    .button-primary {
        background-color: #45454d;
        border-color: #686872;
        color: #f8fafc;
    }

        .button-primary:hover {
            background-color: #565660;
            border-color: #81818b;
            color: #fff;
        }

        .button-primary a,
        .button-primary a:hover {
            color: #f8fafc;
        }


    /* -----------------------------------------
       Info
       ----------------------------------------- */

    .button-info {
        background-color: #172554;
        border-color: #3b82f6;
        color: #bfdbfe;
    }

        .button-info:hover {
            background-color: #1e3a8a;
            border-color: #60a5fa;
            color: #dbeafe;
        }

        .button-info a,
        .button-info a:hover {
            color: #bfdbfe;
        }


    /* -----------------------------------------
       Accent
       ----------------------------------------- */

    .button-accent {
        background-color: #4c0519;
        border-color: #f43f5e;
        color: #fecdd3;
    }

        .button-accent:hover {
            background-color: #881337;
            border-color: #fb7185;
            color: #ffe4e6;
        }

        .button-accent a,
        .button-accent a:hover {
            color: #fecdd3;
        }


    /* -----------------------------------------
       Approve
       ----------------------------------------- */

    .button-approve {
        background-color: #052e16;
        border-color: #22c55e;
        color: #bbf7d0;
    }

        .button-approve:hover {
            background-color: #14532d;
            border-color: #4ade80;
            color: #dcfce7;
        }

        .button-approve a,
        .button-approve a:hover {
            color: #bbf7d0;
        }


    /* -----------------------------------------
       Caution
       ----------------------------------------- */

    .button-caution {
        background-color: #422006;
        border-color: #d97706;
        color: #fde68a;
    }

        .button-caution:hover {
            background-color: #713f12;
            border-color: #f59e0b;
            color: #fef3c7;
        }

        .button-caution a,
        .button-caution a:hover {
            color: #fde68a;
        }


    /* -----------------------------------------
       Error
       ----------------------------------------- */

    .button-error {
        background-color: #450a0a;
        border-color: #ef4444;
        color: #fecaca;
    }

        .button-error:hover {
            background-color: #7f1d1d;
            border-color: #f87171;
            color: #fee2e2;
        }

        .button-error a,
        .button-error a:hover {
            color: #fecaca;
        }


    /* -----------------------------------------
       Light
       ----------------------------------------- */

    .button-light {
        background-color: #1e293b;
        border-color: #475569;
        color: #e2e8f0;
    }

        .button-light:hover {
            background-color: #334155;
            border-color: #64748b;
            color: #f8fafc;
        }

        .button-light a,
        .button-light a:hover {
            color: #e2e8f0;
        }


    /* -----------------------------------------
       Light Small
       ----------------------------------------- */

    .button-light-small {
        color: #e2e8f0;
        background-color: #1e293b;
        border-color: #475569;
    }

        .button-light-small:hover {
            color: #f8fafc;
            background-color: #334155;
            border-color: #64748b;
        }

        .button-light-small a,
        .button-light-small a:hover {
            color: #e2e8f0;
        }


    /* -----------------------------------------
       Check
       ----------------------------------------- */

    .button-check {
        background-color: #45454d;
        border-color: #686872;
        color: #f8fafc;
    }

        .button-check:hover {
            background-color: #565660;
            border-color: #81818b;
            color: #fff;
        }


    /* -----------------------------------------
       Image Button
       ----------------------------------------- */

    .imgagebutton {
        background-color: transparent;
        border-color: #475569;
    }

        .imgagebutton:hover {
            border-color: #94a3b8;
        }


    /* -----------------------------------------
       Disabled
       ----------------------------------------- */

    button:disabled,
    .button:disabled,
    button:hover:disabled,
    .button:hover:disabled,
    .button-primary:disabled,
    .button-primary:hover:disabled,
    .button-info:disabled,
    .button-info:hover:disabled,
    .button-accent:disabled,
    .button-accent:hover:disabled,
    .button-approve:disabled,
    .button-approve:hover:disabled,
    .button-caution:disabled,
    .button-caution:hover:disabled,
    .button-error:disabled,
    .button-error:hover:disabled,
    .button-check:disabled,
    .button-check:hover:disabled,
    .button-light:disabled,
    .button-light:hover:disabled,
    .button-light-small:disabled,
    .button-light-small:hover:disabled {
        color: #64748b;
        background-color: #1e293b;
        border-color: #334155;
        cursor: not-allowed;
        box-shadow: none;
        transform: none;
        opacity: 0.7;
    }
}
