.tool-content {
    box-shadow: var(--card-shadow);
    border: 1px solid var(--border-color);
    border-radius: .6em;
    overflow: hidden;
    position: relative;
    display: flex;
}

/*左侧操作栏*/
.button-operate {
    width: 430px;
    background-color: #f8f9ff;
    border-left: solid 1px #e5e5e5;
}

.button-operate > label {
    font-weight: bold;
    display: block;
    text-align: center;
    font-size: 15px;
    line-height: 50px;
}

.menu-operate {
    display: flex;
    flex-direction: column;
    gap: 1em;
    padding: 0 1em;
}

.menu-operate .input-group {
    display: flex;
    align-items: center;
    justify-content: start;
    position: relative;
    width: 100%;
    gap: 0 12px;
}

.menu-operate .input-group > label {
    min-width: 70px;
    text-align: right;
}

/*按钮*/
.btn {
    outline: none;
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 36px;
    padding: 0 12px;
    color: #333;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    box-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);
    font-family: var(--font-simple);
}

.btn .ripple {
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 0;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    opacity: 0;
    z-index: 1;
    animation: ripple-effect 0.6s ease-out forwards;
}

.btn-group {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.btn-purple {
    color: rgb(93 79 248 / 95%);
    border-color: rgb(93 79 248);
    background: transparent;
    width: fit-content;
    display: flex;
    flex: 1;
    height: 39px;
}

.btn-purple svg {
    fill: #fff;
}

.btn-generate {
    justify-content: start;
    margin-left: 82px;
}

.btn-generate button {
    color: #fff;
    background: rgb(93 79 248 / 95%);
}

.btn-red {
    color: #fff;
    background-color: rgb(242 55 55 / 95%);
    border-color: rgb(242 55 55 / 95%);
}

.btn-red svg {
    fill: #fff;
}


/* 关键动画：扩散 + 淡出 */
@keyframes ripple-effect {
    0% {
        width: 0;
        height: 0;
        opacity: 0.4;
    }
    100% {
        width: 300px;
        height: 300px;
        opacity: 0;
    }
}

/*下拉框*/
.menu-operate .input-group .custom-select {
    position: relative;
    width: 100%;
}

.menu-operate .input-group .custom-select button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-right: 10px;
    gap: 0 6px;
    width: 100%;
    height: 38px;
}

.menu-operate .input-group .select-dropdown {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    width: max-content;
    min-width: 100%;
    max-height: 300px;
    overflow-y: auto;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 7px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    list-style: none;
    margin: 0;
    padding: 2px 0;
    white-space: nowrap;
}

.select-dropdown li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    margin: 3px 5px;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    color: #333;
    font-size: 13.7px;
    transition: background-color 0.2s ease;
    white-space: nowrap;
}

.select-dropdown li:hover,
.select-dropdown li[aria-selected="true"] {
    background-color: #f5f5f5;
}

.select-dropdown li .check-icon {
    flex: 0 0 15px;
    width: 15px;
    height: 15px;
    opacity: 0;
    display: block !important;
}

.select-dropdown li[aria-selected="true"] .check-icon {
    opacity: 1;
}

/*范围框*/
.menu-operate .input-group .input-range {
    width: 100%;
    height: 5px;
    background-color: #d6d1ff;
    border-radius: 2px;
}

.menu-operate .input-group .input-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #f5f4ff;
    cursor: pointer;
    border: 3px solid #887eff;
    box-shadow: 0 0 3px 3px rgb(226 223 255 / 20%);
}

/*输入框*/
.menu-operate .input-group .input-text {
    display: flex;
    flex: 1;
    height: 40px;
    border: solid 1px #ddd;
    background-color: #fff;
    padding: 0 12px;
    border-radius: 7px;
    font-family: var(--font-simple);
    outline: none;
    font-size: 14px;
    box-shadow: inset 0 1px 4px rgb(211 198 255 / 20%), 0 0 0 2px rgba(224, 224, 224, 0.1);
}

.menu-operate .input-group .input-text:focus {
    border-color: #5a4df8;
    background-color: #f8f7fd;
    box-shadow: inset 0 1px 4px rgba(90, 77, 248, 0.2), 0 0 0 2px rgba(90, 77, 248, 0.1);
}

.menu-operate .input-group input[type="color"] {
    display: flex;
    width: 32px;
    height: 32px;
    background-color: #fff;
    border-radius: 5px;
    position: absolute;
    top: 4px;
    right: 4px;
}

.menu-operate .input-group input[type="color" i]::-webkit-color-swatch-wrapper {
    padding: 0;
}

.menu-operate .input-group input[type="color" i]::-webkit-color-swatch {
    border-radius: 5px;
    border-width: 0;
}

/*相册模板*/
.menu-operate .input-group .button-options {
    display: flex;
    align-items: center;
    justify-content: start;
    flex-wrap: wrap;
    gap: 7px;
}

.menu-operate .input-group .button-options .button-option {
    width: 38px;
    height: 38px;
    border-radius: 4px;
    object-fit: cover;
    cursor: pointer;
    transition: border-color 0.2s ease;
}

.menu-operate .input-group .button-options .button-option:hover img {
    border: solid 2px #8278ff;
}

.menu-operate .input-group .button-options .button-option input[type="radio"] {
    display: none;
}

.menu-operate .input-group .button-options .button-option input[type="radio"]:checked + img {
    border: solid 2px #8278ff;
}

.menu-operate .input-group .button-options .button-option img {
    width: 36px;
    height: 36px;
    border-radius: 4px;
    object-fit: cover;
    box-shadow: 0 0 5px 0 rgb(0 0 0 / 20%);
    transition: border-color 0.2s;
}

.button-preview {
    flex: 1;
    margin-bottom: 1em;
}

.button-preview > .label {
    font-weight: bold;
    display: block;
    text-align: center;
    font-size: 15px;
    line-height: 50px;
}

.button-wrapper {
    width: 100%;
    padding: 0 1em;
}

.button-container {
    width: 100%;
    min-height: 660px;
    background-image: repeating-conic-gradient(#f8f8f8 0 25%, #fff 0 50%);
    background-size: 20px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.button-container button:hover {
    transform: scale(1.05);
}

@media (max-width: 768px) {
    .tool-content {
        border-width: 0;
        flex-direction: column;
        box-shadow: none;
    }

    .button-wrapper {
        border: solid 1px #ddd;
        padding: 1em;
    }

    .button-operate {
        border: solid 1px #e5e5e5;
        width: calc(100% - 2px);
        padding-bottom: 1em;
    }

    .menu-operate .input-group > label {
        min-width: 54px;
    }

    .btn-generate {
        margin-left: 64px;
    }
}