@import url('./common/layout.css');
@import url('../component/header/header.css');

.wrap {
    max-width: 600px;
    padding-top: 38px;
    padding-bottom: 40px;
}

.title {
    position: relative;
    z-index: 0;
    margin: 0 0 30px;
    font-family: var(--wall-hand);
    font-size: 46px;
    font-weight: 400;
    line-height: 1.2;
    text-align: center;
}

.title::after {
    content: '';
    position: absolute;
    z-index: -1;
    right: -5px;
    bottom: 3px;
    left: -5px;
    height: 14px;
    transform: rotate(-2deg);
    border-radius: 5px 3px 7px 2px;
    background: #ffe993;
}

article {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 23px;
    width: 100%;
    max-width: 400px;
}

.inputBox {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    min-width: 0;
}

.inputBox label {
    color: #3f3b40;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.5;
}

.inputBox input {
    width: 100%;
    min-width: 0;
    min-height: 47px;
    padding: 12px 14px;
    border: 1px solid #dedad8;
    border-radius: 8px;
    color: var(--wall-ink);
    background: #fff;
    font-size: 13px;
    line-height: 1.6;
}

.inputBox input::placeholder {
    color: #aaa5aa;
}

.inputBox input:focus {
    border-color: #dd8bb0;
    outline: none;
    box-shadow: 0 0 0 3px #f9dfeb;
}

.inputBox input[type='text'] {
    padding-right: 38px;
}

.inputBox .lottie {
    position: absolute;
    top: 41px;
    right: 13px;
    width: 22px;
    height: 22px;
    pointer-events: none;
}

.inputBox input[type='file'] {
    padding: 8px;
    color: #858087;
    background: #faf8f6;
    font-size: 12px;
}

.inputBox input[type='file']::file-selector-button {
    margin-right: 10px;
    padding: 6px 12px;
    border: 1px solid #e6dcd9;
    border-radius: 5px;
    color: #5b5358;
    background: #fff;
    font: inherit;
    cursor: pointer;
}

.inputBox > .helperText,
.buttons > p {
    color: #c04d70;
    font-size: 11px;
    font-weight: 400;
    line-height: 1.65;
    overflow-wrap: anywhere;
}

.helperText:empty,
.buttons > p:empty {
    display: none;
}

.defaultText {
    min-height: 45px;
    padding: 11px 13px;
    border-radius: 7px;
    color: #78727a;
    background: #f2eeeb;
    font-size: 13px;
    overflow-wrap: anywhere;
}

.buttons {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
    margin-top: 8px;
}

.buttons button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 47px;
    padding: 12px 20px;
    border: 0;
    border-radius: 8px;
    color: #fff;
    background-color: var(--wall-pink) !important;
    font-size: 14px;
    font-weight: 600;
}

.buttons button:disabled {
    background-color: #efbbd1 !important;
}

.buttons a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    color: #858087;
    font-size: 12px;
    text-underline-offset: 4px;
    cursor: pointer;
}

.buttons #withdrawBtn {
    color: #9f8e95;
}

.deleteFile {
    padding-left: 10px;
    color: #c04d70;
    cursor: pointer;
}

#toastContainer {
    position: fixed;
    z-index: 101;
    right: 24px;
    bottom: 24px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
    max-width: calc(100vw - 48px);
}

.toastMessage {
    padding: 11px 22px;
    border-radius: 10px;
    color: #fff;
    background: #343036;
    box-shadow: 0 5px 20px #24202626;
    opacity: 0;
    transition: opacity 180ms ease;
}

.profileUploadContainer {
    position: relative;
    width: 100px;
    height: 100px;
    margin-bottom: 2px;
    border-radius: 50%;
    background: #ece7e3;
}

.profileRemoveButton {
    position: absolute;
    z-index: 3;
    top: -3px;
    right: -3px;
    display: none;
    align-items: center;
    justify-content: center;
    width: 27px;
    height: 27px;
    border: 2px solid #fff;
    border-radius: 50%;
    color: #fff;
    background: #c95883;
    font-size: 18px;
    line-height: 1;
}

.profileUploadButton {
    position: absolute;
    z-index: 2;
    bottom: -7px;
    left: 50%;
    min-height: 30px;
    padding: 4px 17px;
    transform: translateX(-50%);
    border: 1px solid #ead9df;
    border-radius: 20px;
    color: #6d4e5a;
    background: #fff7fa;
    font-size: 12px;
    white-space: nowrap;
    cursor: pointer;
}

#profilePreview {
    display: block;
    width: 100%;
    height: 100%;
    border: 3px solid #fff;
    border-radius: 50%;
    object-fit: cover;
}

@media (hover: hover) and (pointer: fine) {
    .buttons button:not(:disabled):hover {
        box-shadow: 0 3px 10px #d7659630;
    }

    .buttons a:hover {
        color: #b44c7a;
        text-decoration: underline;
    }
}

@media (max-width: 680px) {
    .wrap {
        max-width: 520px;
        padding-top: 32px;
        padding-bottom: 32px;
    }

    .title {
        margin-bottom: 28px;
        font-size: 41px;
    }

    article {
        gap: 22px;
    }
}

.upload-status {
    width: 100%;
    color: #a65075;
    font-size: 11px;
    line-height: 1.7;
    text-align: center;
}
.upload-status:empty { display: none; }
.selected-upload {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-top: 5px;
}
.selected-upload[hidden] { display: none; }
.selected-upload img {
    width: 56px;
    height: 56px;
    border: 1px solid #eadce2;
    border-radius: 50%;
    object-fit: cover;
}
.selected-upload button {
    min-height: 34px;
    padding: 6px 12px;
    border: 1px solid #ead3de;
    border-radius: 6px;
    color: #a44f73;
    background: #fff4f9;
    font-size: 12px;
}

.inputBox > label {
    position: relative;
}

.inputBox > label::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 22px;
    height: 2px;
    border-radius: 2px;
    background: #dd8bb0;
    opacity: 0;
    pointer-events: none;
}

.inputBox:focus-within > label::after {
    opacity: 1;
}

@media (prefers-reduced-motion: no-preference) {
    html[data-input='pointer'] .inputBox > label::after {
        transform: scaleX(.65);
        transform-origin: left;
        transition: opacity 160ms var(--motion-ease-out), transform 180ms var(--motion-ease-out);
    }

    html[data-input='pointer'] .inputBox:focus-within > label::after {
        transform: scaleX(1);
    }
}

@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
    html[data-input='pointer'] .buttons button:not(:disabled):not(:active):hover {
        transform: translateY(-1px);
    }
}
