* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Poppins', Arial, Helvetica, sans-serif;
}

:root {
    --color-primary-lighter: #E7E2E8;
    --color-primary-light: #C498CD;
    --color-primary-base: #AD00CF;
    --color-primary-dark: #690081;
    --color-primary-darker: #3A0042;

    --input-color: #808080;
    --input-font-size-medium: 1rem;
    --input-font-size-smaller: 0.6rem;
}

body {
    margin: 2rem;
}

.display-none {
    display: none;
}

.display-flex {
    display: flex;
    flex-direction: column;
}

.display-flex-center {
    display: flex;
    justify-content: space-evenly;
}

.block-scroll {
    height: 100vh;
    overflow: hidden;
}

.modal-container {
    width: 100vw;
    height: 100vh;
    background-color: #00000040;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 0;
    left: 0;
}

.modal {
    min-width: 40%;
    height: 60%;
    background-color: #FFF;
    padding: 1rem;
    border-radius: 0.5rem;
    overflow: overlay;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    box-shadow: rgba(0, 0, 0, 0.1) 0px 4px 12px;
}

.modal-header {
    height: 10%;
    border-bottom: 1px solid #DDDDDD;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.modal-body {
    height: 80%;
    overflow: overlay;
}

.modal-footer {
    height: 10%;
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
}

.text-field {
    width: 100%;
    display: flex;
    flex-direction: column;
    cursor: text;
}

.text-field fieldset {
    width: 100%;
    padding: 0 10px 5px 0;
    border: 1px solid var(--input-color);
    border-radius: 5px;
    color: var(--text-placeholder);
    position: relative;
    transition: border-color .2s, color .2s;
}

.text-field fieldset:has(input:focus) {
    border-width: 2px;
    border-color: var(--color-primary-base);
}

.text-field fieldset label, .text-field fieldset span {
    padding: 0 5px;
    pointer-events: none;
}

.text-field fieldset legend {
    max-width: 0.01px;
    margin-left: 7px;
    font-size: var(--input-font-size-smaller);
    opacity: 0;
    transition: max-width .1s
}

.text-field fieldset input {
    width: 97%;
    border: none;
    font-size: var(--input-font-size-medium);
    outline: none;
    padding-left: 10px;
    background-color: transparent;
}

.text-field fieldset input:focus + legend,
.text-field fieldset input:valid + legend {
    max-width: 100%;
}

.text-field fieldset .placeholder {
    margin-left: 7px;
    font-size: var(--input-font-size-medium);
    font-weight: 500;
    color: var(--input-color);
    position: absolute;
    top: -5%;
    left: 0;
    transition: font-size .2s, top .2s;
}

.text-field fieldset input:focus ~ .placeholder {
    color: var(--color-primary-base);
}

.text-field fieldset input:focus ~ .placeholder,
.text-field fieldset input:valid ~ .placeholder {
    font-size: var(--input-font-size-smaller);
    top: -50%;
}

.text-field fieldset:has(input.invalid) {
    border-width: 2px;
    border-color: #FF0000;
}

.text-field fieldset input.invalid ~ .placeholder {
    color: #FF0000;
}

button.modal-close-button {
    background: none;
    border: none;
    font-size: 1rem;
    color: #DDDDDD;
    cursor: pointer;
}

button.modal-close-button img {
    width: 1rem;
}

button.image-button {
    background: none;
    border: none;
    cursor: pointer;
}

button.image-button img {
    width: 1.5rem;
}

button.default-button {
    background-color: var(--color-primary-base);
    padding: 0 0.5rem;
    border: none;
    border-radius: 0.3rem;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    color: #FFFFFF;
    transition: .3s;
}

button.default-button:hover {
    filter: brightness(1.2);
}

table {
    width: 100%;
    border-spacing: 0;
    border-collapse: separate;
    border: 1px solid var(--color-primary-base);
    border-radius: 0.5rem;
    overflow: hidden;
}

table thead {
    background-color: var(--color-primary-base);
    color: #FFFFFF;
    border: none;
}

table thead th {
    padding: 0 5px;
}

table thead th.left, table tbody td.left {
    text-align: left;
}

table thead th.center, table tbody td.center {
    text-align: center;
}

table thead th.right, table tbody td.right {
    text-align: right;
}

table tbody {
    border: 1px solid #000000;
}

table tbody td {
    padding: 5px;
}

table tbody tr {
    transition: .3s;
}

table tbody tr:hover {
    background-color: var(--color-primary-light);
}

table tbody tr:not(:last-child) td {
    border-bottom: 1px solid var(--color-primary-lighter);
}

form#product-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

section#main {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

div#page-header {
    width: 100%;
    display: flex;
    justify-content: space-between;
}

button#new-product img {
    width: 2rem;
}