.modal { dialog { transition: transform 0.25s, opacity 0.25s; overflow-y: auto; overflow-x: hidden; opacity: 0; z-index: -1; max-height: 100%; width: calc(100% - 16px); left: 50%; top: 50%; transform: translateX(-50%); position: fixed; display: flex; flex-direction: column; background: rgb(35, 35, 35); border-radius: 16px; border: none; margin: 0; @media screen and (min-width: 801px) { & { max-width: 80%; } } > header { padding: 16px; display: flex; align-items: center; justify-content: space-between; > div { display: flex; gap: 8px; align-items: center; } .button-icon { background-color: transparent; border: 1px solid rgba(150, 150, 150, 0.2); } svg { min-width: 20px; } h6 { margin: 0; font-size: 16px; font-weight: 500; line-height: 24px; letter-spacing: -0.011em; } } > main { flex: 1; } > footer { margin-top: 1rem; display: flex; justify-content: center; } } &.modal--internalOpen dialog { transform: translate(-50%, -50%); opacity: 1; } &.modal--open dialog { z-index: 10; } &.modal--actions footer { margin-top: 1rem; display: flex; justify-content: space-between; } }