*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

.locked {
    /* transition: max-height 0.5s ease, opacity 0.5s ease; */
    max-height: 0;
    opacity: 0;
    display: none;
}

/* Active/open state */
.locked.active {
    display: flex;
    flex-direction: column;
    gap: 6px;
    opacity: 1;
    max-height: 999px;
}

.hidden {
    display: none !important;
}

.downloadSvgIcon {
    width: 24px;
    height: 24px;
    display: inline-block;
    color: currentColor;
    background-color: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%3E%3Cpath%20d%3D%22M19%2018.0002C19.9282%2018.0002%2020.8185%2017.6314%2021.4749%2016.9751C22.1312%2016.3187%2022.5%2015.4285%2022.5%2014.5002C22.5%2013.5719%2022.1312%2012.6817%2021.4749%2012.0253C20.8185%2011.3689%2019.9282%2011.0002%2019%2011.0002H18C18.1459%2010.3502%2018.1481%209.68061%2018.0065%209.02979C17.8649%208.37898%2017.5823%207.75963%2017.1748%207.20712C16.7672%206.65461%2016.2427%206.17976%2015.6313%205.80968C15.0198%205.43959%2014.3334%205.18152%2013.6111%205.0502C12.8888%204.91887%2012.1449%204.91687%2011.4218%205.04431C10.6986%205.17174%2010.0105%205.42612%209.39658%205.79291C8.15675%206.53368%207.29467%207.68737%206.99999%209.0002C5.93394%208.95749%204.88553%209.2706%204.03426%209.88589C3.18299%2010.5012%202.58181%2011.3804%202.33366%2012.373C2.08551%2013.3656%202.20582%2014.4099%202.67399%2015.327C3.14216%2016.2441%203.92907%2016.977%204.89999%2017.4002M12%2013.0002V22.0002M12%2022.0002L9%2019.0002M12%2022.0002L15%2019.0002%22%20stroke%3D%22%23354052%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22/%3E%3C/svg%3E") no-repeat center / contain;
    mask: url("data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%3E%3Cpath%20d%3D%22M19%2018.0002C19.9282%2018.0002%2020.8185%2017.6314%2021.4749%2016.9751C22.1312%2016.3187%2022.5%2015.4285%2022.5%2014.5002C22.5%2013.5719%2022.1312%2012.6817%2021.4749%2012.0253C20.8185%2011.3689%2019.9282%2011.0002%2019%2011.0002H18C18.1459%2010.3502%2018.1481%209.68061%2018.0065%209.02979C17.8649%208.37898%2017.5823%207.75963%2017.1748%207.20712C16.7672%206.65461%2016.2427%206.17976%2015.6313%205.80968C15.0198%205.43959%2014.3334%205.18152%2013.6111%205.0502C12.8888%204.91887%2012.1449%204.91687%2011.4218%205.04431C10.6986%205.17174%2010.0105%205.42612%209.39658%205.79291C8.15675%206.53368%207.29467%207.68737%206.99999%209.0002C5.93394%208.95749%204.88553%209.2706%204.03426%209.88589C3.18299%2010.5012%202.58181%2011.3804%202.33366%2012.373C2.08551%2013.3656%202.20582%2014.4099%202.67399%2015.327C3.14216%2016.2441%203.92907%2016.977%204.89999%2017.4002M12%2013.0002V22.0002M12%2022.0002L9%2019.0002M12%2022.0002L15%2019.0002%22%20stroke%3D%22%23354052%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22/%3E%3C/svg%3E") no-repeat center / contain;
}

#downloadSvg {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

#downloadSvg[data-mode="multi"] .downloadSvgIcon {
    display: none;
}

input:disabled {
    background: #fff;
}

html {
    font-family: 'TT Firs Neue';
}

.pageLoader {
    position: fixed;
    inset: 0;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.pageLoader__spinner {
    width: 28px;
    height: 28px;
    display: block;
    color: #354052;
    background-color: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20viewBox%3D%220%200%2020%2020%22%20fill%3D%22none%22%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%3E%3Cpath%20d%3D%22M9.99969%203.0918V5.85495M9.99969%2014.1444V16.9076M3.0918%209.99969H5.85495M14.1444%209.99969H16.9076M5.1156%205.11507L7.06945%207.06892M12.931%2012.9304L14.8849%2014.8843M5.1156%2014.8843L7.06945%2012.9304M12.931%207.06892L14.8849%205.11507%22%20stroke%3D%22currentColor%22%20stroke-width%3D%221.8%22%20stroke-linecap%3D%22round%22/%3E%3C/svg%3E") no-repeat center / contain;
    mask: url("data:image/svg+xml,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20viewBox%3D%220%200%2020%2020%22%20fill%3D%22none%22%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%3E%3Cpath%20d%3D%22M9.99969%203.0918V5.85495M9.99969%2014.1444V16.9076M3.0918%209.99969H5.85495M14.1444%209.99969H16.9076M5.1156%205.11507L7.06945%207.06892M12.931%2012.9304L14.8849%2014.8843M5.1156%2014.8843L7.06945%2012.9304M12.931%207.06892L14.8849%205.11507%22%20stroke%3D%22currentColor%22%20stroke-width%3D%221.8%22%20stroke-linecap%3D%22round%22/%3E%3C/svg%3E") no-repeat center / contain;
    animation: btn_spin 0.8s linear infinite;
}

@keyframes btn_spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}


body {
    padding: 60px 90px;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
    /* display: none; <- Crashes Chrome on hover */
    -webkit-appearance: none;
    margin: 0;
    /* <-- Apparently some margin are still there even though it's hidden */
}

.container {
    width: 100%;
    min-height: calc(100dvh - 120px);
    display: flex;
    justify-content: center;
    gap: 40px;
}

.container.is-sending {
    justify-content: center;
}

.container.is-sending .leftSide {
    position: absolute;
    left: -9999px;
    top: 0;
}

.container.is-sending .rightSide {
    margin: 0 auto;
}

.leftSide {
    display: flex;
    flex-direction: column;
    height: 100%;
    gap: 32px;
    position: sticky;
    top: 60px;
    align-self: flex-start;
}

.rightSide {
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 22.5px;
    max-width: 592px;
    width: 592px;
}

.photoOptions {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.photoOptions>div:not(:last-child):not(.locked) {
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.photoOptions>div:not(.locked) {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.photoMusicAuthor,
.photoMusicName {
    display: flex;
    flex-direction: column;
    gap: 10px
}

.photoTextInput {
    display: flex;
    align-items: flex-start;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    position: relative;
    padding: 4px;
    flex-grow: 1;
    width: 100%;
}

.photoTextInput.is-without {
    border-color: transparent;
    background: #f5f5f5;
}

.photoTextInput.is-error {
    border-color: #e34b4b;
    box-shadow: 0 0 0 2px rgba(227, 75, 75, 0.4);
    background: rgba(227, 75, 75, 0.12);
}

.photoTextInput.is-error input::placeholder,
.photoTextInput.is-error textarea::placeholder {
    color: rgba(227, 75, 75, 0.7) !important;
}

.photoTextInput.is-without input,
.photoTextInput.is-without textarea {
    color: rgba(0, 0, 0, 0.45);
}

.photoTextInput.is-without .alignButtons button::before,
.photoTextInput.is-without #addEmoji::before {
    opacity: 0.3;
}

.photoTextControls {
    display: flex;
    gap: 4px;
}

#customDate {
    width: 100%;
}

#addEmoji {
    cursor: pointer;
    border: none;
    background: transparent;
    transition: all 0.3s ease;
    height: 32px;
    width: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.25s;
    position: relative;
}

#addEmoji img{
    height: 22px;
    width: 22px;
}

#addEmoji:hover {
    background: #f2f3f4;
}

#addEmoji.is-open {
    background: #f2f3f4;
}

.addEmojiModal {
    z-index: 10;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    background: white;
    border: 1px solid #ddd;
    border-radius: 18px;
    padding: 10px;
    width: 200px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    position: absolute;
    top: 45px;
    right: 0;
    z-index: 100;
}

.addEmojiModal.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    z-index: 100;
}

.sizeLimitModal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.sizeLimitModal.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.sizeLimitModal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.sizeLimitModal.is-open .sizeLimitModal__backdrop {
    opacity: 1;
}

.sizeLimitModal__content {
    position: relative;
    z-index: 1;
    background: #fff;
    border-radius: 24px;
    padding: 20px;
    width: min(360px, 90vw);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
    text-align: center;
    opacity: 0;
    transform: translateY(8px) scale(0.98);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.sizeLimitModal.is-open .sizeLimitModal__content {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.sizeLimitModal__iconWrap {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(242, 153, 74, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
}

.sizeLimitModal__icon {
    width: 24px;
    height: 24px;
    color: #f2994a;
    display: block;
}

.sizeLimitModal__title {
    font-size: 20px;
    font-weight: 600;
    color: #111;
    margin-bottom: 4px;
}

.sizeLimitModal__text {
    font-size: 16px;
    line-height: 1.4;
    color: rgba(17, 17, 17, 0.7);
    margin-bottom: 16px;
}

.sizeLimitModal__close {
    height: 44px;
    padding: 0 18px;
    border-radius: 12px;
    border: none;
    background: #000;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    transition: 0.25s;
}

.sizeLimitModal__close:hover {
    opacity: 0.75;
}

.emoji-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 4px;
    justify-items: center;
}

.emoji-grid span {
    font-size: 20px;
    cursor: pointer;
    transition: transform 0.25s;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 32px;
    width: 32px;
    border-radius: 12px;
    background: transparent;
}

.emoji-grid span img {
    width: 24px;
    height: 24px;
    object-fit: contain;
    display: block;
    pointer-events: none;
}

.emoji-grid span:hover {
    background: #eee;
}

.photoTextInput input,
.photoTextInput textarea {
    flex-grow: 1;
    width: 100%;
    border: none;
    outline: none;
    padding: 10px 12px;
    font-size: 16px;
    min-height: 40px;
    line-height: 20px;
    font-family: 'Inter', sans-serif;
    border-radius: 12px;
    background: transparent;
    resize: none;
    overflow: hidden;
    margin: -4px 0;
}

.photoTextInput input::placeholder,
.photoTextInput textarea::placeholder {
    color: #c3cad0;
}

.dateClearButton {
    display: flex;
    align-items: center;
    border: none;
    background: #000;
    color: #fff;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    height: 36px;
    padding: 0 14px;
    border-radius: 8px;
    white-space: nowrap;
    transition: 0.25s;
}

.dateClearButton:hover {
    opacity: 0.7;
}

.dateClearButton:focus {
    outline: none;
}

.photoFormItem {
    position: relative;
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;
    display: inline-block;
    cursor: pointer;
}

.photoFormItem.selected {
    outline: 3px solid rgba(0, 0, 0, 0.25);
    outline-offset: 3px;
    border-radius: 12px;
}

.photoFormItem img {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 12px;
    object-fit: cover;
    transition: transform 0.3s ease, filter 0.3s ease;
}

.photoFormItem button {
    position: absolute;
    bottom: 10px;
    left: 10px;
    right: 10px;
    transform: translateY(10px);
    opacity: 0;
    transition: all 0.3s ease;
    background-color: #000;
    color: #fff;
    height: 36px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    line-height: 100%;
    border: none;
    cursor: pointer;
    z-index: 10;
}

.photoFormItem:not(.selected):hover button {
    opacity: 1;
    transform: translateY(0);
}

.photoFormItem:hover img {
    filter: brightness(0.8);
}

.photoFormOptions {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
}

input[type="radio"] {
    display: none;
}

input[type="radio"]:checked+label.buttonSelector {
    background-color: #D4EBE9;
}

.photoFontSizeSelectors input[type="radio"]:disabled + label.buttonSelector {
    cursor: not-allowed !important;
    pointer-events: none;
    border-color: transparent;
    background: #f5f5f5;
    color: #d4d4d4;
}

.sectionTitle {
    display: flex;
    flex-direction: row;
    gap: 8px;
}

.sectionTitle h3 {
    font-size: 16px;
    font-weight: 600;
    line-height: 20px;
}

.sectionTitle span {
    font-size: 16px;
    font-weight: 400;
    line-height: 20px;
    color: transparent;
    background-image: linear-gradient(90deg, #9aa0a6 0%, #f0f0f0 10%, #9aa0a6 20%);
    background-size: 180% 100%;
    background-position: 0% 0%;
    -webkit-background-clip: text;
    background-clip: text;
    animation: uploadPlaceholderShimmer 2.5s ease-in-out infinite;
}

.photoFont .sectionTitle span,
.photoFontSize .sectionTitle span,
.photoSize .sectionTitle span {
    color: #9aa0a6;
    background-image: none;
    animation: none;
}

.photoText:has(.photoTextInput.is-without) .sectionTitle span,
.photoDate:has(.photoTextInput.is-without) .sectionTitle span,
.photoMusicAuthor:has(.photoTextInput.is-without) .sectionTitle span,
.photoMusicName:has(.photoTextInput.is-without) .sectionTitle span {
    display: none;
}

.photoFontSelectors {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(284px, 1fr));
    gap: 10px;
    width: 100%;
}

.photoFontSelectors>div {
    display: flex;
}

.photoFontSelectors label {
    width: 100%;
}

.photoFontSelectors input[type="radio"] {
    display: none;
}

.fontOption {
    width: 284px;
    height: 44px;
    display: flex;
    align-items: center;
    gap: 12px;
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 0 16px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.2s ease;
}

.order-mode .photoFontSelectors {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.order-mode .photoFontSelectors > div,
.order-mode .fontOption {
    width: 100%;
}

.fontOption {
    width: 284px;
    height: 40px;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    padding: 0 10px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.2s ease;
}

.fontOption::before {
    content: "";
    width: 20px;
    height: 20px;
    border: 2px solid #ccc;
    border-radius: 50%;
    flex-shrink: 0;
}

.fontOption span {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.alignButtons button {
    color: #354052;
}

.alignButtons button::before {
    content: "";
    display: block;
    width: 20px;
    height: 20px;
    background-color: currentColor;
    mask-repeat: no-repeat;
    mask-position: center;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    -webkit-mask-position: center;
    -webkit-mask-size: contain;
}

.alignSeparator {
    width: 1px;
    height: 20px;
    background: rgba(0, 0, 0, 0.12);
    display: block;
    flex: 0 0 1px;
    margin: 6px 0;
}

.alignSeparatorSignature {
    margin-left: 4px;
}

.signatureToggleGroup {
    display: flex;
    gap: 4px;
    align-items: center;
}

.signatureToggle {
    height: 32px;
    width: 32px;
    flex: 0 0 32px;
    min-width: 32px;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: #354052;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: color 0.2s ease, background-color 0.2s ease;
    position: relative;
}

.signatureToggle::before {
    content: "";
    display: block;
    width: 20px;
    height: 20px;
    background-color: currentColor;
    mask-repeat: no-repeat;
    mask-position: center;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    -webkit-mask-position: center;
    -webkit-mask-size: contain;
}

.signatureToggle:hover {
    background: #f2f3f4;
}

.signatureToggle.is-active {
    background: #55AFA9;
    color: #fff;
}

.signatureToggle.is-with::before {
    mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 20H7M14 20H21M6.90002 15H13.8M10.2 6.3L16 20M5 20L11 4H13L20 20' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 20H7M14 20H21M6.90002 15H13.8M10.2 6.3L16 20M5 20L11 4H13L20 20' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

.signatureToggle.is-without::before {
    mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 20H7M14 20H20M6.90002 15H13.8M13 13L16 20M5 20L9.09 9.09399M10.181 6.183L11 4H13L16.904 12.924M3 3L21 21' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 20H7M14 20H20M6.90002 15H13.8M13 13L16 20M5 20L9.09 9.09399M10.181 6.183L11 4H13L16.904 12.924M3 3L21 21' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

.alignButtons #left::before {
    mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 6H20M4 12H14M4 18H18' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 6H20M4 12H14M4 18H18' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

.alignButtons #center::before {
    mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 6H20M8 12H16M6 18H18' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 6H20M8 12H16M6 18H18' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

.alignButtons #right::before {
    mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 6H20M10 12H20M6 18H20' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 6H20M10 12H20M6 18H20' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

#addEmoji {
    color: #354052;
}

#addEmoji::before {
    content: "";
    display: block;
    width: 20px;
    height: 20px;
    background-color: currentColor;
    mask-repeat: no-repeat;
    mask-position: center;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    -webkit-mask-position: center;
    -webkit-mask-size: contain;
    mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20.985 12.5281C21.0921 10.7059 20.6426 8.89425 19.6962 7.33345C18.7497 5.77266 17.3511 4.53654 15.6858 3.78911C14.0205 3.04169 12.1673 2.81828 10.3721 3.14855C8.57687 3.47882 6.92452 4.34714 5.63427 5.6383C4.34403 6.92947 3.47688 8.58243 3.14789 10.3779C2.81889 12.1733 3.04361 14.0263 3.79222 15.6911C4.54083 17.3559 5.77794 18.7536 7.33941 19.699C8.90087 20.6443 10.7129 21.0925 12.535 20.9841M16 19.0001H22M19 16.0001V22.0001M9 10.0001H9.01M15 10.0001H15.01M9.5 15.0001C10.158 15.6401 11.06 16.0001 12 16.0001C12.94 16.0001 13.842 15.6401 14.5 15.0001' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20.985 12.5281C21.0921 10.7059 20.6426 8.89425 19.6962 7.33345C18.7497 5.77266 17.3511 4.53654 15.6858 3.78911C14.0205 3.04169 12.1673 2.81828 10.3721 3.14855C8.57687 3.47882 6.92452 4.34714 5.63427 5.6383C4.34403 6.92947 3.47688 8.58243 3.14789 10.3779C2.81889 12.1733 3.04361 14.0263 3.79222 15.6911C4.54083 17.3559 5.77794 18.7536 7.33941 19.699C8.90087 20.6443 10.7129 21.0925 12.535 20.9841M16 19.0001H22M19 16.0001V22.0001M9 10.0001H9.01M15 10.0001H15.01M9.5 15.0001C10.158 15.6401 11.06 16.0001 12 16.0001C12.94 16.0001 13.842 15.6401 14.5 15.0001' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

.fontOption::before {
    content: "";
    width: 20px;
    height: 20px;
    border: 2px solid #ccc;
    border-radius: 50%;
    flex-shrink: 0;
}

input[type="radio"]:checked+.fontOption::before {
    border-color: #55AFA9;
    background-image: radial-gradient(circle, #55AFA9 0 5px, transparent 6px);
    background-repeat: no-repeat;
    background-position: center;
}

.submitButton button {
    background-color: #000;
    border-radius: 12px;
    min-height: 50px;
    width: 100%;
    height: 100%;
    font-size: 16px;
    font-weight: 600;
    color: #fff;
    line-height: 100%;
    cursor: pointer;
    outline: none;
    border: none;
    transition: background 0.25s;
}

.buttonSelector {
    width: 166px;
    height: 40px;
    border-radius: 12px;
    background-color: #fff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.2s ease;
    display: inline-block;
    place-content: center;
    text-align: center;
    width: 100%;
    display: flex;
    align-items: center;
    position: relative;
}

.buttonSelector::before {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: 12px;
    border: 3px solid transparent;
    pointer-events: none;
}

input[type="radio"]:checked+label.buttonSelector::before {
    border-color: #55AFA9;
}

.buttonSelector:hover {
    background-color: #f0f0f0;
}

.submitButton button:hover {
    background-color: #333;
}

.bounce {
    animation-name: bounce;
    animation-duration: .3s;
}

@keyframes bounce {
    0% {
        transform: translateX(0px);
        timing-function: ease-in;
    }

    37% {
        transform: translateX(10px);
        timing-function: ease-out;
    }

    55% {
        transform: translateX(-10px);
        timing-function: ease-in;
    }

    73% {
        transform: translateX(7px);
        timing-function: ease-out;
    }

    82% {
        transform: translateX(-7px);
        timing-function: ease-in;
    }

    91% {
        transform: translateX(4px);
        timing-function: ease-out;
    }

    96% {
        transform: translateX(-4px);
        timing-function: ease-in;
    }

    100% {
        transform: translateX(0px);
        timing-function: ease-in;
    }

}

.buttonSelector,
.submitButton button,
.fontOption {
    font-family: inherit;
}

.photoSizeButtons {
    display: flex;
    gap: 10px;
}

.photoFontSizeSelectors {
    display: flex;
    gap: 10px;
}

.alignButtons {
    display: flex;
}

.alignButtons button {
    background: transparent;
    cursor: pointer;
    border: none;
    -webkit-focus-ring-color: transparent;
    height: 32px;
    width: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.25s;
    position: relative;
}

.alignButtons button:hover {
    background: #f2f3f4;
}

.alignButtons button:focus {
    outline: none;
}

.alignButtons button img {
    width: 20px;
    height: 20px;
}

.order-mode .photoForm,
.order-mode .photoSize {
    display: none !important;
}

.orderStepsPanel {
    width: 100%;
    margin-bottom: 12px;
    border-radius: 12px;
    background: #fff;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.orderStepsTitle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    font-size: 26px;
    line-height: 30px;
}

.orderStepsStep {
    font-size: 14px;
    font-weight: 600;
    height: 28px;
    padding: 1.5px 10px 0;
    border-radius: 12px;
    background: #eee;
    display: flex;
    align-items: center;
}

.orderStepsAccordion {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.orderStepsEmpty {
    padding: 10px;
    border-radius: 10px;
    background: #f3f3f3;
    font-size: 13px;
}

.orderStepCard {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid transparent;
    border-radius: 18px;
}

.orderStepCard.is-open {
    border: 1px solid rgba(0, 0, 0, 0.12);
    box-shadow: 0 6px 20px rgba(24, 32, 56, 0.08);
    outline: 2px solid #29ba3b;
    outline-offset: 2px;
}

.orderStepCard.is-done {
    border: 1px solid rgba(0, 0, 0, 0.12);
}

.orderStepCard.is-open .orderStepHeader {
    /*background: #ffd7b0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);*/
    border-radius: 17px 17px 0 0;
    background: #29ba3a5f;
}

.orderStepCard.is-done .orderStepHeader {
    background: #29ba3a1c;
}

.orderStepHeader {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    padding: 12px 20px;
    background: #f5f5f5;
    border-radius: 17px;
}

.orderStepHeaderText {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.orderStepTitle {
    font-weight: 600;
    font-size: 16px;
    color: rgba(0, 0, 0, 0.3);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.orderStepDot {
    margin: 0 6px;
    font-weight: 700;
}

.orderStepCard.is-open .orderStepTitle,
.orderStepCard.is-done .orderStepTitle {
    color: #1f1f1f;
}

.orderStepSub {
    font-size: 14px;
    color: rgba(0, 0, 0, 0.3);
    white-space: nowrap;
}

.orderStepCard.is-open .orderStepSub,
.orderStepCard.is-done .orderStepSub {
    color: #5b5b5b;
}

.orderStepActions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.orderStepEdit {
    font-family: 'TT Firs Neue';
    border: 1px solid rgba(0, 0, 0, 0.12);
    background: #fff;
    color: #000;
    border-radius: 12px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 500;
    height: 36px;
    display: flex;
    align-items: center;
    padding: 1px 14px 0;
}

.orderStepBody {
    display: none;
    padding: 20px;
    background: #fff;
    border-radius: 0 0 17px 17px;
}

.orderStepCard.is-open .orderStepBody {
    display: block;
}

.orderStepControls {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.orderStepControls.is-compact {
    gap: 0;
}

.orderStepControls.is-compact .photoOptions {
    display: none;
}

.orderStepControlsMount {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.orderStepControlsMount.is-compact {
    gap: 0;
}

.orderStepsFinal {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.orderStepsSuccess {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 18px 20px 16px;
    border-radius: 16px;
    background: #f2f7f6;
    border: 1px solid rgba(85, 175, 169, 0.3);
    color: #1f2a37;
    text-align: center;
}

.orderStepsSuccessIcon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    color: #29ba3b;
    margin: 0 auto 4px;
}

.orderStepsSuccessIcon svg {
    width: 100%;
    height: 100%;
    display: block;
}

.orderStepsSuccessTitle {
    font-size: 20px;
    font-weight: 600;
    line-height: 1.2;
}

.orderStepsSuccessText {
    font-size: 16px;
    line-height: 1.4;
    color: rgba(31, 42, 55, 0.7);
}

.orderStepsError {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 18px 20px;
    border-radius: 16px;
    background: #fff6f6;
    border: 1px solid rgba(226, 68, 68, 0.3);
    color: #1f2a37;
    text-align: center;
}

.orderStepsErrorTitle {
    font-size: 20px;
    font-weight: 600;
    line-height: 1.2;
    color: #d92d20;
}

.orderStepsErrorText {
    font-size: 16px;
    line-height: 1.4;
    color: rgba(31, 42, 55, 0.7);
}

.orderStepsDownload {
    font-family: 'TT Firs Neue';
    background-color: #000;
    border-radius: 12px;
    min-height: 56px;
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 16px;
    font-weight: 600;
    color: #fff;
    line-height: 100%;
    cursor: pointer;
    outline: none;
    border: none;
    transition: background 0.25s;
}

.orderStepsDownload:hover {
    background-color: #333;
}

.orderStepsDownload:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.orderStepsSpinner {
    width: 24px;
    height: 24px;
    display: none;
    color: currentColor;
    background-color: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20viewBox%3D%220%200%2020%2020%22%20fill%3D%22none%22%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%3E%3Cpath%20d%3D%22M9.99969%203.0918V5.85495M9.99969%2014.1444V16.9076M3.0918%209.99969H5.85495M14.1444%209.99969H16.9076M5.1156%205.11507L7.06945%207.06892M12.931%2012.9304L14.8849%2014.8843M5.1156%2014.8843L7.06945%2012.9304M12.931%207.06892L14.8849%205.11507%22%20stroke%3D%22currentColor%22%20stroke-width%3D%221.8%22%20stroke-linecap%3D%22round%22/%3E%3C/svg%3E") no-repeat center / contain;
    mask: url("data:image/svg+xml,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20viewBox%3D%220%200%2020%2020%22%20fill%3D%22none%22%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%3E%3Cpath%20d%3D%22M9.99969%203.0918V5.85495M9.99969%2014.1444V16.9076M3.0918%209.99969H5.85495M14.1444%209.99969H16.9076M5.1156%205.11507L7.06945%207.06892M12.931%2012.9304L14.8849%2014.8843M5.1156%2014.8843L7.06945%2012.9304M12.931%207.06892L14.8849%205.11507%22%20stroke%3D%22currentColor%22%20stroke-width%3D%221.8%22%20stroke-linecap%3D%22round%22/%3E%3C/svg%3E") no-repeat center / contain;
    animation: btn_spin 0.8s linear infinite;
}

.orderStepsIcon {
    width: 24px;
    height: 24px;
    display: inline-block;
    color: currentColor;
    background-color: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%3E%3Cpath%20d%3D%22M6.99996%2018.0002C5.75223%2018.0002%204.55561%2017.5261%203.67334%2016.6822C2.79107%2015.8383%202.29541%2014.6937%202.29541%2013.5002C2.29541%2012.3067%202.79107%2011.1621%203.67334%2010.3182C4.55561%209.4743%205.75223%209.0002%206.99996%209.0002C7.29464%207.68737%208.15672%206.53368%209.39654%205.79291C10.0104%205.42612%2010.6986%205.17174%2011.4217%205.04431C12.1449%204.91687%2012.8888%204.91887%2013.6111%205.0502C14.3333%205.18152%2015.0198%205.43959%2015.6312%205.80968C16.2427%206.17976%2016.7672%206.65461%2017.1747%207.20712C17.5823%207.75963%2017.8649%208.37898%2018.0065%209.02979C18.1481%209.68061%2018.1459%2010.3502%2018%2011.0002H19C19.9282%2011.0002%2020.8185%2011.3689%2021.4748%2012.0253C22.1312%2012.6817%2022.5%2013.5719%2022.5%2014.5002C22.5%2015.4285%2022.1312%2016.3187%2021.4748%2016.9751C20.8185%2017.6314%2019.9282%2018.0002%2019%2018.0002H18M8.99997%2015.0002L12%2012.0002M12%2012.0002L15%2015.0002M12%2012.0002V21.0002%22%20stroke%3D%22%23354052%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22/%3E%3C/svg%3E") no-repeat center / contain;
    mask: url("data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%3E%3Cpath%20d%3D%22M6.99996%2018.0002C5.75223%2018.0002%204.55561%2017.5261%203.67334%2016.6822C2.79107%2015.8383%202.29541%2014.6937%202.29541%2013.5002C2.29541%2012.3067%202.79107%2011.1621%203.67334%2010.3182C4.55561%209.4743%205.75223%209.0002%206.99996%209.0002C7.29464%207.68737%208.15672%206.53368%209.39654%205.79291C10.0104%205.42612%2010.6986%205.17174%2011.4217%205.04431C12.1449%204.91687%2012.8888%204.91887%2013.6111%205.0502C14.3333%205.18152%2015.0198%205.43959%2015.6312%205.80968C16.2427%206.17976%2016.7672%206.65461%2017.1747%207.20712C17.5823%207.75963%2017.8649%208.37898%2018.0065%209.02979C18.1481%209.68061%2018.1459%2010.3502%2018%2011.0002H19C19.9282%2011.0002%2020.8185%2011.3689%2021.4748%2012.0253C22.1312%2012.6817%2022.5%2013.5719%2022.5%2014.5002C22.5%2015.4285%2022.1312%2016.3187%2021.4748%2016.9751C20.8185%2017.6314%2019.9282%2018.0002%2019%2018.0002H18M8.99997%2015.0002L12%2012.0002M12%2012.0002L15%2015.0002M12%2012.0002V21.0002%22%20stroke%3D%22%23354052%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22/%3E%3C/svg%3E") no-repeat center / contain;
}

.orderStepsDownload.is-loading .orderStepsSpinner {
    display: inline-block;
}

.orderStepsDownload.is-loading .orderStepsIcon {
    display: none;
}

.orderComment {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.orderComment textarea {
    font-family: 'TT Firs Neue';
    width: 100%;
    resize: vertical;
    min-height: 70px;
    padding: 10px 14px;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    font-family: inherit;
    font-size: 16px;
    line-height: 21px;
    transition: 0.25s;
}

.orderComment textarea:focus {
    background-color: #fff;
    border: 1px solid #29ba3b;
    box-shadow: 0 0 0 2px rgba(48, 207, 67, 0.25);
    outline: none;
    transition: background-color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

@media (max-width: 1200px) {
    .container {
        width: 100%;
        display: flex;
        flex-direction: column;
        justify-content: center;
        padding: 0;
    }

    .leftSide,
    .rightSide,
    .photoOptions {
        display: contents;
    }

    .container.is-sending .imageUpload {
        position: absolute;
        left: -9999px;
        top: 0;
    }

    .imageUpload {
        order: 1;
        align-self: center;
    }

    .orderStepsPanel {
        order: 2;
    }

    .orderStepControls {
        order: 3;
    }

    .photoForm {
        order: 4;
    }

    .photoSize {
        order: 5;
    }

    .photoMusic {
        order: 6;
    }

    .photoText {
        order: 7;
    }

    .photoDate {
        order: 8;
    }

    .photoFont {
        order: 9;
    }

    .photoFontSize {
        order: 10;
    }

    .submitButton {
        order: 11;
    }

}

@media (max-width: 620px) {
    body {
        padding: 20px 16px 16px 16px;
    }

    .container {
        min-height: auto;
        gap: 20px;
    }

    .photoFormOptions {
        display: grid;
        grid-template-columns: repeat(5, minmax(0, 1fr));
        gap: 10px;
        width: 100%;
        place-items: center;
    }

    .photoFormItem {
        width: 100%;
        height: auto;
        aspect-ratio: 1 / 1;
        flex: 0 0 auto;
    }

    .photoFormItem button {
        display: none;
    }

    .photoFontSelectors div {
        width: 100%;
    }

    .fontOption {
        width: 100%;
    }

    .fontOption span {
        flex: 1;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .alignSeparatorAlign {
        display: none;
    }

    .photoText .photoTextInput {
        flex-wrap: wrap;
        align-items: center;
        row-gap: 8px;
    }

    .photoText .photoTextInput>#customText {
        order: 1;
        width: 100%;
        flex: 0 0 100%;
    }

    .photoText .photoTextInput>.signatureToggleGroup {
        order: 2;
        margin-right: auto;
    }

    .photoText .photoTextInput>.photoTextControls {
        order: 3;
        margin-left: auto;
    }

    .photoText .photoTextInput>.alignSeparatorSignature {
        display: none;
    }

    .photoText .photoTextInput>.addEmojiModal {
        top: calc(100% + 5px);
    }

    .photoOptions>div:not(:last-child) {
        border-bottom: none;
    }

    .orderStepHeader {
        padding: 11px 16px 10px;
    }

    .orderStepBody {
        padding: 16px;
    }

}
