/* --------------- TABLE --------------- */

table {
    width: 100%;
    border: 1px solid #e4e5e7;
    border-collapse: collapse;
}

table thead th {
    background-color: var(--table-header-bg-color);
}

table th {
    padding: 8px;

    font-weight: 700;
    line-height: 1.43;
    color: var(--first-text-color);

    text-align: left;
    border: 1px solid #e4e5e7;
}

table tr {
    background-color: var(--table-first-bg-color);
}

table tr:nth-child(2n) {
    background-color: var(--table-second-bg-color);
}

table tr:hover {
    background-color: var(--table-hover-bg-color);
}

table td {
    padding: 8px;

    font-weight: 500;
    line-height: 1.43;
    color: var(--first-text-color);
    border: 1px solid #e4e5e7;
}

/* --------------- BUTTONS --------------- */

/* Default */

.button {
    padding: 6px 12px;
    min-width: 120px;

    font-size: 14px;
    line-height: 1.43;
    color: #333333;
    background-color: #ffffff;
    border: 1px solid #cccccc;
    border-radius: 2px;

    transition: background-color 200ms ease;
}

.button:hover,
.button:focus {
    background-color: #e6e6e6;
    border-color: #adadad;
}

.button:active {
    border-color: #adadad;
    box-shadow: inset 0 3px 5px rgb(0 0 0 / 13%);
}

/* Primary */

.button.primary {
    color: #ffffff;
    background-color: #428bca;
    border-color: #3b7cb4;
}

.button.primary:hover,
.button.primary:focus {
    background-color: #3a95e4;
}

.button.primary:active {
    background-color: #3a95e4;
    box-shadow: inset 0 3px 5px rgb(0 0 0 / 13%);
}

/* Success */
.button.success {
    color: #ffffff;
    background-color: #3c990b;
    border-color: #12891b;
}

.button.success:hover,
.button.success:focus {
    background-color: #50ab20;
    border-color: #50ab20;
}

.button.success:active {
    box-shadow: inset 0 3px 5px rgb(0 0 0 / 13%);
}

/* Danger */

.button.danger {
    color: #ffffff;
    background-color: #e5343d;
    border-color: #bf2d35;
}

.button.danger:hover,
.button.danger:focus {
    background-color: #e7575e;
}

.button.danger:active {
    box-shadow: inset 0 3px 5px rgb(0 0 0 / 13%);
}

/* --------------- ACTION BUTTONS --------------- */

/* Default */

.action-button {
    width: 25px;
    height: 25px;

    font-size: 11px;
    color: #333333;
    background-color: #ffffff;
    border: 1px solid #cccccc;
    border-radius: 2px;

    transition: background-color 200ms ease;
}

.action-button:hover,
.action-button:focus {
    background-color: #e6e6e6;
    border-color: #adadad;
}

.action-button:active {
    border-color: #adadad;
    box-shadow: inset 0 3px 5px rgb(0 0 0 / 13%);
}

/* Primary */

.action-button.primary {
    color: #fbfbfb;
    background-color: #428bca;
    border-color: #3b7cb4;
}

.action-button.primary:hover,
.action-button.primary:focus {
    background-color: #3a95e4;
}

.action-button.primary:active {
    background-color: #3a95e4;
    box-shadow: inset 0 3px 5px rgb(0 0 0 / 13%);
}

/* Success */
.action-button.success {
    color: #fbfbfb;
    background-color: #3c990b;
    border-color: #12891b;
}

.action-button.success:hover,
.action-button.success:focus {
    background-color: #50ab20;
    border-color: #50ab20;
}

.action-button.success:active {
    box-shadow: inset 0 3px 5px rgb(0 0 0 / 13%);
}

/* Danger */

.action-button.danger {
    color: #fbfbfb;
    background-color: #e5343d;
    border-color: #bf2d35;
}

.action-button.danger:hover,
.action-button.danger:focus {
    background-color: #e7575e;
}

.action-button.danger:active {
    box-shadow: inset 0 3px 5px rgb(0 0 0 / 13%);
}

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

/* Default */

.label {
    padding: 2px 5px;

    font-size: 11px;
    color: #ffffff;
    background-color: #ced0d2;
    border: 1px solid #ced0d2;
    border-radius: 4px;
}

/* Primary */

.label.primary {
    background-color: #3a95e4;
    border-color: #3a95e4;
}

/* Success */

.label.success {
    background-color: #50ab20;
    border-color: #50ab20;
}

/* Info */

.label.info {
    background-color: #53d4fa;
    border-color: #53d4fa;
}

/* Warning */

.label.warning {
    background-color: #ffc751;
    border-color: #ffc751;
}

/* Danger */

.label.danger {
    background-color: #e5343d;
    border-color: #e5343d;
}

/* --------------- PANEL --------------- */

.panel {
    margin-bottom: 5px;

    box-shadow: 0 3px 6px rgb(0 0 0 / 16%), 0 3px 6px rgb(0 0 0 / 23%);
}

.panel-header {
    padding: 5px 10px;

    font-size: 18px;
    font-weight: 600;
    line-height: 1.66;
    letter-spacing: 0.5px;
    color: var(--first-text-color);
    background-color: var(--panel-header-bg-color);
    border-bottom: 1px solid #b7b9bf;
}

.panel-content {
    padding: 15px;

    font-weight: 500;
    line-height: 1.43;
    color: var(--first-text-color);
    background-color: var(--panel-content-bg-color);
}

.panel-actions {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.panel-search-form {
    position: relative;

    margin-left: auto;
    width: 300px;
}

.panel-search-input {
    padding-right: 12px;
}

.panel-search-button {
    position: absolute;
    top: 0;
    right: 0;

    height: 100%;
    width: 35px;

    color: #a699b3;

    background-color: transparent;
    border: none;
}

.panel-footer {
    padding: 10px 15px;

    background-color: #f7f9fa;

    border-top: 1px solid #e1e6ef;
}

/* --------------- FORMS --------------- */

.form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-input {
    width: 100%;
    padding: 5px 12px;

    font-family: inherit;
    font-size: 14px;
    color: #555;
    font-weight: 500;
    line-height: 1.43;

    border: 1px solid #ccc;
    border-radius: 4px;

    /* box-shadow: inset 0 1px 1px rgb(0 0 0 / 8%); */

    transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
}

.form-input:focus {
    border-color: #009688;
    box-shadow: none;
    outline: 0;
}

.form-input-danger,
.form-input-danger:hover {
    border-color: #e5343d;
}

.form-input::placeholder {
    color: #a699b3;
}

.form-input-label {
    display: flex;
    flex-direction: column;
    gap: 5px;

    font-weight: 700;
    line-height: 1.43;
}

.form-input-error {
    padding-left: 15px;
    font-size: 12px;
    font-weight: 500;
    color: #e5343d;
}

/* --------------- MODAL --------------- */

.backdrop {
    position: fixed;
    top: 0;
    left: 0;

    display: block;
    width: 100%;
    height: 100%;

    background-color: rgba(0, 0, 0, 0.5);

    opacity: 1;

    transition: opacity 250ms ease-in-out;
}

.backdrop.is-hidden {
    opacity: 0;
    pointer-events: none;
}

.backdrop.is-hidden .modal {
    transform: translate(50%, 50%);

    transition: transform 5000ms ease-in-out;
}

/* Default */

.modal {
    position: fixed;
    top: 40%;
    left: 50%;

    width: 600px;

    color: #374767;

    background-color: #fff;
    box-shadow: 0 5px 15px rgb(0 0 0 / 50%);

    /* transform: translate(-50%, -50%); */
    transform: translate(-50%, -50%);

    /* transition: transform 5000ms ease-in-out; */
}

.modal-header {
    position: relative;

    padding: 15px;

    background-color: #f7f9fa;

    border-bottom: 1px solid #e1e6ef;
}

.modal-title {
    font-size: 27px;
    font-weight: 500;
    line-height: 1.43;
    text-align: center;
}

.modal-content-message {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.43;
}

.modal-close-button {
    position: absolute;
    top: 0;
    right: 0;

    font-size: 20px;
    color: #c6c7c8;
    border: none;
    background-color: transparent;

    transition: color 250ms ease-in-out;
}

.modal-close-button:hover,
.modal-close-button:focus {
    color: #7d7e80;
}

.modal-content {
    padding: 15px;

    line-height: 1.43;
}

.modal-footer {
    padding: 15px;

    border-top: 1px solid #e5e5e5;
}

.modal-actions {
    display: flex;
    justify-content: end;
    gap: 10px;
}

.modal-actions-button {
    min-width: 50px;
}

/* Danger */

.modal.danger .modal-header {
    background-color: #e5343d;
}

.modal.danger .modal-title {
    color: #ffffff;
}
