/**
 * UUID生成器工具样式 - 现代化设计
 */

/* 通用容器 */
.aiowtb-uuid-generator {
    max-width: 100%;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    color: #333;
}

/* 主容器卡片式设计 */
.aiowtb-uuid-generator .aiowtb-card {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    margin-bottom: 20px;
    overflow: hidden;
    transition: box-shadow 0.3s ease;
}

.aiowtb-uuid-generator .aiowtb-card:hover {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.aiowtb-uuid-generator .aiowtb-card-header {
    padding: 16px 20px;
    background-color: #f7f9fc;
    border-bottom: 1px solid #eaedf3;
}

.aiowtb-uuid-generator .aiowtb-card-title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #3a3a3a;
}

.aiowtb-uuid-generator .aiowtb-card-body {
    padding: 20px;
}

/* 表单 */
.aiowtb-uuid-generator .aiowtb-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.aiowtb-uuid-generator .aiowtb-form-group {
    margin-bottom: 10px;
}

.aiowtb-uuid-generator .aiowtb-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #4a5568;
    font-size: 18px;
}

.aiowtb-uuid-generator .aiowtb-input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    box-sizing: border-box;
    font-size: 14px;
    transition: all 0.2s ease;
    background-color: #fff;
}

.aiowtb-uuid-generator .aiowtb-input:focus {
    border-color: #4c9aff;
    box-shadow: 0 0 0 2px rgba(76, 154, 255, 0.2);
    outline: none;
}

.aiowtb-uuid-generator .aiowtb-input:hover:not(:focus) {
    border-color: #cbd5e0;
}

.aiowtb-uuid-generator select.aiowtb-input {
    appearance: none;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="%234a5568" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M6 9l6 6 6-6"/></svg>');
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 16px;
    padding-right: 36px;
}

/* 单选按钮和复选框样式 */
.aiowtb-uuid-generator .aiowtb-radio-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 10px;
    margin-top: 8px;
}

.aiowtb-uuid-generator .aiowtb-radio-label,
.aiowtb-uuid-generator .aiowtb-checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;

    border-radius: 6px;
    font-size: 16px;
    transition: background-color 0.2s;
}

.aiowtb-uuid-generator .aiowtb-radio-label:hover,
.aiowtb-uuid-generator .aiowtb-checkbox-label:hover {
    background-color: #f7fafc;
}

.aiowtb-uuid-generator .aiowtb-radio-label input[type="radio"],
.aiowtb-uuid-generator .aiowtb-checkbox-label input[type="checkbox"] {
    margin-right: 8px;
    accent-color: #4c9aff;
}

.aiowtb-uuid-generator .aiowtb-hint {
    color: #718096;
    font-size: 12px;
    margin: 4px 0 0;
    line-height: 1.4;
}

/* 按钮 */
.aiowtb-uuid-generator .aiowtb-button {
    background-color: #4c9aff;
    color: white;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1.4;
    box-shadow: 0 2px 5px rgba(76, 154, 255, 0.2);
}

.aiowtb-uuid-generator .aiowtb-button:hover {
    background-color: #3d8df5;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(76, 154, 255, 0.25);
}

.aiowtb-uuid-generator .aiowtb-button:active {
    transform: translateY(0);
    box-shadow: 0 1px 3px rgba(76, 154, 255, 0.2);
}

.aiowtb-uuid-generator .aiowtb-button-secondary {
    background-color: #f7fafc;
    color: #4a5568;
    border: 1px solid #e2e8f0;
    box-shadow: none;
}

.aiowtb-uuid-generator .aiowtb-button-secondary:hover {
    background-color: #edf2f7;
    border-color: #cbd5e0;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.aiowtb-uuid-generator .aiowtb-button svg,
.aiowtb-uuid-generator .aiowtb-button .dashicons {
    margin-right: 6px;
}

.aiowtb-uuid-generator .aiowtb-form-actions {
    margin-top: 24px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 12px;
}

/* 加载动画 */
.aiowtb-uuid-generator .aiowtb-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    margin-left: 10px;
    border: 2px solid rgba(76, 154, 255, 0.2);
    border-top: 2px solid #4c9aff;
    border-radius: 50%;
    animation: aiowtb-spinner 0.8s linear infinite;
}

@keyframes aiowtb-spinner {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 消息 */
.aiowtb-uuid-generator .aiowtb-message {
    padding: 12px 16px;
    margin-bottom: 20px;
    border-radius: 6px;
    font-size: 14px;
    display: flex;
    align-items: flex-start;
    animation: aiowtb-fade-in 0.3s ease;
}

@keyframes aiowtb-fade-in {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.aiowtb-uuid-generator .aiowtb-message-error {
    background-color: #fff5f5;
    color: #c53030;
    border-left: 4px solid #e53e3e;
}

.aiowtb-uuid-generator .aiowtb-message-warning {
    background-color: #fffaf0;
    color: #c05621;
    border-left: 4px solid #ed8936;
}

.aiowtb-uuid-generator .aiowtb-message-success {
    background-color: #f0fff4;
    color: #2f855a;
    border-left: 4px solid #48bb78;
}

.aiowtb-uuid-generator .aiowtb-message-info {
    background-color: #e6f6ff;
    color: #2b6cb0;
    border-left: 4px solid #4c9aff;
}

/* 结果区域 */
.aiowtb-uuid-generator .aiowtb-results-wrapper {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    animation: aiowtb-fade-in 0.4s ease;
}

.aiowtb-uuid-generator .aiowtb-results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid #eaedf3;
    background-color: #f7f9fc;
}

.aiowtb-uuid-generator .aiowtb-results-header h4 {
    margin: 0;
    color: #3a3a3a;
    font-size: 16px;
    font-weight: 600;
}

.aiowtb-uuid-generator .aiowtb-uuid-results {
    max-height: 400px;
    overflow-y: auto;
    padding: 12px;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e0 #f7fafc;
}

.aiowtb-uuid-generator .aiowtb-uuid-results::-webkit-scrollbar {
    width: 8px;
}

.aiowtb-uuid-generator .aiowtb-uuid-results::-webkit-scrollbar-track {
    background: #f7fafc;
}

.aiowtb-uuid-generator .aiowtb-uuid-results::-webkit-scrollbar-thumb {
    background-color: #cbd5e0;
    border-radius: 4px;
    border: 2px solid #f7fafc;
}

.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    margin-bottom: 8px;
    background-color: #f7fafc;
    border-radius: 6px;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper:hover {
    background-color: #edf2f7;
    border-left-color: #4c9aff;
    transform: translateX(2px);
}

.aiowtb-uuid-generator .aiowtb-uuid-item {
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 14px;
    word-break: break-all;
    color: #4a5568;
}

.aiowtb-uuid-generator .aiowtb-copy-btn {
    background: none;
    border: none;
    color: #a0aec0;
    cursor: pointer;
    padding: 5px;
    margin-left: 8px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
}

.aiowtb-uuid-generator .aiowtb-copy-btn:hover {
    color: #4c9aff;
    background-color: rgba(76, 154, 255, 0.1);
}

.aiowtb-uuid-generator .aiowtb-copy-btn .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
}

/* 版本特定选项卡容器 */
.aiowtb-uuid-generator .aiowtb-version-options {
    background-color: #f7fafc;
    border-radius: 6px;
    padding: 16px;
    margin-top: 10px;
    border-left: 3px solid #4c9aff;
    animation: aiowtb-fade-in 0.3s ease;
}

/* 吐司消息 */
.aiowtb-toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    max-width: 350px;
    background-color: #2d3748;
    color: white;
    padding: 12px 20px;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 10000;
    transition: transform 0.3s, opacity 0.3s;
    transform: translateY(100px);
    opacity: 0;
    display: flex;
    font-size: 16px;
    align-items: center;
}

.aiowtb-toast-show {
    transform: translateY(0);
    opacity: 1;
}

.aiowtb-toast-success {
    background-color: #38a169;
}

.aiowtb-toast-error {
    background-color: #e53e3e;
}

.aiowtb-toast::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    margin-right: 12px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.aiowtb-toast-success::before {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="%23ffffff" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M22 11.08V12a10 10 0 1 1-5.93-9.14"></path><polyline points="22 4 12 14.01 9 11.01"></polyline></svg>');
}

.aiowtb-toast-error::before {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="%23ffffff" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"></circle><line x1="15" y1="9" x2="9" y2="15"></line><line x1="9" y1="9" x2="15" y2="15"></line></svg>');
}

/* 响应式布局 */
@media (max-width: 768px) {
    .aiowtb-uuid-generator .aiowtb-form {
        grid-template-columns: 1fr;
    }
    
    .aiowtb-uuid-generator .aiowtb-radio-group {
        grid-template-columns: 1fr;
    }
    
    .aiowtb-uuid-generator .aiowtb-results-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .aiowtb-uuid-generator .aiowtb-form-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .aiowtb-uuid-generator .aiowtb-button {
        width: 100%;
    }
    
    .aiowtb-uuid-generator .aiowtb-uuid-item-wrapper {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .aiowtb-uuid-generator .aiowtb-copy-btn {
        margin-left: 0;
        margin-top: 8px;
        align-self: flex-end;
    }
}

/* 移动设备优化 */
@media (max-width: 480px) {
    .aiowtb-uuid-generator .aiowtb-card-body {
        padding: 15px;
    }
    
    .aiowtb-uuid-generator .aiowtb-label {
        font-size: 16px;
    }
    
    .aiowtb-uuid-generator .aiowtb-uuid-item {
        font-size: 12px;
    }
    
    .aiowtb-toast {
        left: 20px;
        right: 20px;
        max-width: calc(100% - 40px);
    }
}



/* 补充样式 - 为新增功能特性提供支持 */

/* 输入框成功高亮效果 */
.aiowtb-uuid-generator .aiowtb-input-success {
    border-color: #48bb78 !important;
    box-shadow: 0 0 0 2px rgba(72, 187, 120, 0.2) !important;
    transition: all 0.3s ease !important;
}

/* 复制高亮效果 */
.aiowtb-uuid-generator .aiowtb-copied {
    background-color: rgba(76, 154, 255, 0.1) !important;
    border-left-color: #48bb78 !important;
    transition: all 0.3s ease !important;
}

/* 粘性操作按钮 */
.aiowtb-uuid-generator .aiowtb-sticky-actions {
    position: sticky;
    bottom: 20px;
    background-color: rgba(255, 255, 255, 0.95);
    padding: 15px;
    margin: 0 -20px -20px;
    border-top: 1px solid #eaedf3;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
    z-index: 100;
    border-radius: 0 0 8px 8px;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
}



/* 为版本选项添加过渡动画 */
.aiowtb-uuid-generator .aiowtb-version-options {
    transition: all 0.3s ease-in-out;
}

/* 为结果区域添加动画效果 */
.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper {
    opacity: 0;
    animation: aiowtb-fade-slide-in 0.3s ease forwards;
}

@keyframes aiowtb-fade-slide-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 让每个结果项依次延迟出现 */
.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper:nth-child(1) { animation-delay: 0.05s; }
.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper:nth-child(2) { animation-delay: 0.1s; }
.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper:nth-child(3) { animation-delay: 0.15s; }
.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper:nth-child(4) { animation-delay: 0.2s; }
.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper:nth-child(5) { animation-delay: 0.25s; }
.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper:nth-child(6) { animation-delay: 0.3s; }
.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper:nth-child(7) { animation-delay: 0.35s; }
.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper:nth-child(8) { animation-delay: 0.4s; }
.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper:nth-child(9) { animation-delay: 0.45s; }
.aiowtb-uuid-generator .aiowtb-uuid-item-wrapper:nth-child(10) { animation-delay: 0.5s; }

/* 提高结果容器的可读性 */
.aiowtb-uuid-generator .aiowtb-uuid-results:empty::after {
    content: '生成的UUID将显示在这里';
    display: block;
    padding: 20px;
    text-align: center;
    color: #a0aec0;
    font-style: italic;
}

/* 修复小屏幕上粘性按钮的样式问题 */
@media (max-width: 768px) {
    .aiowtb-uuid-generator .aiowtb-sticky-actions {
        flex-direction: column;
        padding: 12px;
    }
    
    .aiowtb-uuid-generator .aiowtb-copied {
        background-color: rgba(76, 154, 255, 0.1) !important;
        transform: none !important;
    }
}

/* 增强表单元素在触摸设备上的交互体验 */
@media (hover: none) {
    .aiowtb-uuid-generator .aiowtb-radio-label,
    .aiowtb-uuid-generator .aiowtb-checkbox-label {
        padding: 12px;
    }
    
    .aiowtb-uuid-generator .aiowtb-button {
        padding: 12px 20px;
    }
}

/* 高亮显示已复制项的图标 */
.aiowtb-uuid-generator .aiowtb-copied .aiowtb-copy-btn {
    color: #48bb78;
    background-color: rgba(72, 187, 120, 0.1);
}

/* 信息图标和提示优化 */
.aiowtb-uuid-generator .aiowtb-message {
    position: relative;
    padding-left: 40px;
}

.aiowtb-uuid-generator .aiowtb-message::before {
    content: '';
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

.aiowtb-uuid-generator .aiowtb-message-info::before {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="%232b6cb0" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"></circle><line x1="12" y1="16" x2="12" y2="12"></line><line x1="12" y1="8" x2="12.01" y2="8"></line></svg>');
}

.aiowtb-uuid-generator .aiowtb-message-error::before {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="%23c53030" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"></circle><line x1="15" y1="9" x2="9" y2="15"></line><line x1="9" y1="9" x2="15" y2="15"></line></svg>');
}

.aiowtb-uuid-generator .aiowtb-message-warning::before {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="%23c05621" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z"></path><line x1="12" y1="9" x2="12" y2="13"></line><line x1="12" y1="17" x2="12.01" y2="17"></line></svg>');
}

.aiowtb-uuid-generator .aiowtb-message-success::before {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="%232f855a" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M22 11.08V12a10 10 0 1 1-5.93-9.14"></path><polyline points="22 4 12 14.01 9 11.01"></polyline></svg>');
} 