.tool-content {
    box-shadow: var(--card-shadow);
    border: 1px solid var(--border-color);
    padding: 1.2em;
    border-radius: .6em;
    position: relative;
}

.tool-content .item-tool {
    display: flex;
    flex-direction: column;
    font-family: var(--font-simple);
    position: relative;
}

.tool-content .item-select {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1.2em 1.5em;
    flex-direction: row;
    margin: 1.2em 0;
    border-bottom: solid 1px #ddd;
    padding-bottom: 1.2em;
}

.tool-content .item-select .options {
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.tool-content .item-select .options > label {
    font-family: var(--font-simple);
    font-size: 14px;
}

.tool-content .item-select .options .custom-select {
    position: relative;
}

/*下拉框*/
.tool-content .item-select .options .custom-select button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-right: 8px;
    gap: 0 6px;
    width: 120px;
}

.tool-content .item-select .options .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;
}

/* hover 背景 */
.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;
}

.tool-content .operate-buttons {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

.input-number {
    border: 1px solid #ddd;
    background-color: var(--main-bg);
    width: 120px;
    height: 36px;
    line-height: 36px;
    padding: 0 12px;
    border-radius: 6px;
    font-family: var(--font-simple);
    outline: none;
    font-size: 14px;
    text-align: center;
}

.input-number: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);
}

.input-color {
    border: 1px solid #ddd;
    background-color: var(--main-bg);
    width: 120px;
    height: 36px;
    line-height: 36px;
    padding: 3px;
    text-indent: 12px;
    border-radius: 6px;
    font-family: var(--font-simple);
    outline: none;
    font-size: 14px;
    cursor: pointer;
}

input[type="color" i]::-webkit-color-swatch-wrapper {
    padding: 0;
}

.input-color::-webkit-color-swatch {
    border: none;
    border-radius: 4px;
}

/*按钮样式*/
.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-purple {
    color: #fff;
    background-color: rgb(93 79 248 / 95%);
    border-color: var(--primary-color);
}

.btn-green {
    color: #fff;
    background-color: rgba(34, 197, 94, 0.95);
    border-color: #22c55e;
}

.input-textarea {
    border: solid 1px #ddd;
    background-color: var(--main-bg);
    width: 100%;
    min-height: 200px;
    padding: 12px;
    border-radius: 7px;
    font-family: var(--font-simple);
    outline: none;
    resize: none;
    position: relative;
    margin-top: 0.7em;
}

.input-textarea: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);
}

.result {
    margin-top: 1.2em;
    display: none;
}

.result > p {
    margin-bottom: 0.6em;
}

.result > p > span {
    color: var(--primary-color);
    font-weight: 500;
    font-family: var(--font-simple);
    font-size: 15.5px;
}

.result .font-items {
    display: flex;
    flex-direction: column;
    gap: 1.2em;
}

.result .font-items .font-item {
    border: solid 1px #eee;
    width: 100%;
}

.result .font-items .font-item p {
    margin-bottom: 0;
}

.result .font-items .font-item .font-head {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 30px;
    width: 100%;
    height: 42px;
    background-color: var(--main-bg);
    padding: 0 15px;
    font-weight: 500;
    color: #333;
    font-family: var(--font-simple);
}

.result .font-items .font-item .font-head p {
    font-size: 14px;
}

.result .font-items .font-item .font-head p span {
    color: var(--primary-color);
}

.result .font-items .font-item .font-body {
    padding: 10px 15px;
}

/* 关键动画：扩散 + 淡出 */
@keyframes ripple-effect {
    0% {
        width: 0;
        height: 0;
        opacity: 0.4;
    }
    100% {
        width: 300px;
        height: 300px;
        opacity: 0;
    }
}

@media (max-width: 768px) {
    .tool-content {
        padding: .8em !important;
        box-shadow: unset;
    }

    .operate-buttons .btn {
        line-height: 32px !important;
        height: 32px !important;
        padding: 0 8px !important;
    }

    .tool-content .mobile-item label span {
        height: 16px !important;
        padding: 0 4px !important;
        margin: 0 2px !important;
        font-size: 12px !important;
    }

    .result .font-items .font-item .font-head{
        gap: 0 10px;
        padding: 10px;
        flex-wrap: wrap;
        height: auto;
    }

    .result .font-items .font-item .font-body {
        padding: 10px 10px;
    }

    .tool-content .item-select{
        gap: 1.2em;
    }

    .tool-content .item-select .options > label{
        font-size: 13px;
    }

    .btn {
        height: 32px;
    }

    .input-number {
        height: 32px;
        line-height: 32px;
        width: 110px;
    }

    .input-color{
        width: 110px;
    }

    .tool-content .item-select .options .custom-select button{
        width: 110px;
    }

}