/* Main Container Styles */
.sort-words-container {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    color: #333;
    line-height: 1.6;
}

/* Hero Section */
.sort-words-hero {
    background: linear-gradient(135deg, #6e8efb 0%, #a777e3 100%);
    border-radius: 12px;
    padding: 40px;
    margin-bottom: 40px;
    color: white;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.sort-words-hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100" preserveAspectRatio="none"><path fill="rgba(255,255,255,0.05)" d="M0,0 L100,0 L100,100 L0,100 Z" /></svg>');
    background-size: cover;
    opacity: 0.5;
}

.sort-words-title {
    font-size: 2.8rem;
    margin-bottom: 10px;
    font-weight: 800;
    position: relative;
    z-index: 1;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.sort-words-subtitle {
    font-size: 1.4rem;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
    opacity: 0.9;
}

.sort-words-hero-illustration {
    height: 120px;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 500 120"><path fill="rgba(255,255,255,0.2)" d="M30,60 L70,30 L110,90 L150,40 L190,80 L230,20 L270,70 L310,50 L350,100 L390,30 L430,80 L470,40" stroke="white" stroke-width="3" fill="none" stroke-linecap="round"/><text x="250" y="50" fill="white" font-family="Arial" font-size="14" text-anchor="middle" opacity="0.7">A B C D E F G H I J K L M N O P Q R S T U V W X Y Z</text></svg>') center no-repeat;
    margin: 20px auto 0;
    position: relative;
    z-index: 1;
}

/* Tool Section */
.sort-words-tool-section {
    margin-bottom: 60px;
}

.sort-words-tool-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
}

.sort-words-input-container, 
.sort-words-output-container {
    flex: 1;
    min-width: 300px;
}

.sort-words-label {
    display: block;
    margin-bottom: 12px;
    font-weight: 600;
    color: #444;
    font-size: 1.1rem;
}

.sort-words-textarea {
    width: 100%;
    min-height: 200px;
    padding: 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    resize: vertical;
    transition: border-color 0.3s;
    background-color: #f9f9f9;
}

.sort-words-textarea:focus {
    border-color: #6e8efb;
    outline: none;
    box-shadow: 0 0 0 3px rgba(110, 142, 251, 0.2);
}

.sort-words-options {
    margin: 20px 0;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.sort-words-option-group {
    flex: 1;
    min-width: 200px;
}

.sort-words-option-label {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
    cursor: pointer;
    user-select: none;
}

.sort-words-option-label input {
    margin-right: 10px;
    opacity: 0;
    position: absolute;
}

.sort-words-radio-custom {
    width: 18px;
    height: 18px;
    border: 2px solid #6e8efb;
    border-radius: 50%;
    margin-right: 10px;
    position: relative;
    transition: all 0.3s;
}

.sort-words-option-label input[type="radio"]:checked + .sort-words-radio-custom::after {
    content: '';
    width: 10px;
    height: 10px;
    background: #6e8efb;
    border-radius: 50%;
    position: absolute;
    top: 2px;
    left: 2px;
}

.sort-words-checkbox-custom {
    width: 18px;
    height: 18px;
    border: 2px solid #6e8efb;
    border-radius: 4px;
    margin-right: 10px;
    position: relative;
    transition: all 0.3s;
}

.sort-words-option-label input[type="checkbox"]:checked + .sort-words-checkbox-custom::after {
    content: '✓';
    position: absolute;
    top: -3px;
    left: 2px;
    color: #6e8efb;
    font-weight: bold;
}

.sort-words-action-btn {
    background: linear-gradient(135deg, #6e8efb 0%, #a777e3 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    width: 100%;
}

.sort-words-action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(110, 142, 251, 0.3);
}

.sort-words-action-btn:active {
    transform: translateY(0);
}

/* Output Section */
.sort-words-output-container {
    background-color: #f5f7ff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.sort-words-output-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.sort-words-output-title {
    font-size: 1.3rem;
    color: #444;
    margin: 0;
}

.sort-words-copy-btn {
    background-color: #e1e8ff;
    color: #6e8efb;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    transition: background-color 0.2s;
}

.sort-words-copy-btn:hover {
    background-color: #d0d9ff;
}

.sort-words-copy-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.sort-words-copy-icon {
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 6px;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%236e8efb"><path d="M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"/></svg>') center no-repeat;
}

.sort-words-output-content {
    min-height: 200px;
    padding: 15px;
    background-color: white;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 1rem;
    white-space: pre-wrap;
    word-wrap: break-word;
    overflow-y: auto;
    max-height: 300px;
}

.sort-words-stats {
    display: flex;
    justify-content: space-between;
    margin-top: 15px;
    font-size: 0.9rem;
    color: #666;
}

.sort-words-stat {
    display: flex;
    align-items: center;
}

.sort-words-stat::before {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    margin-right: 6px;
    background-color: #6e8efb;
    border-radius: 2px;
    opacity: 0.7;
}

/* Info Boxes Section */
.sort-words-info-section {
    margin-bottom: 60px;
}

.sort-words-section-title {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 40px;
    color: #444;
    position: relative;
}

.sort-words-section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, #6e8efb 0%, #a777e3 100%);
    margin: 15px auto 0;
    border-radius: 2px;
}

.sort-words-info-boxes {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: center;
}

.sort-words-info-box {
    flex: 1;
    min-width: 280px;
    max-width: 350px;
    background: white;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: transform 0.3s, box-shadow 0.3s;
    text-align: center;
}

.sort-words-info-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
}

.sort-words-info-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #6e8efb 0%, #a777e3 100%);
}

.sort-words-icon-time {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm.5-13H11v6l5.25 3.15.75-1.23-4.5-2.67z"/></svg>');
    background-size: 30px;
    background-repeat: no-repeat;
    background-position: center;
}

.sort-words-icon-accurate {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41L9 16.17z"/></svg>');
    background-size: 30px;
    background-repeat: no-repeat;
    background-position: center;
}

.sort-words-icon-versatile {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M3 5v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2H5c-1.11 0-2 .9-2 2zm12 4c0 1.66-1.34 3-3 3s-3-1.34-3-3 1.34-3 3-3 3 1.34 3 3zm-9 8c0-2 4-3.1 6-3.1s6 1.1 6 3.1v1H6v-1z"/></svg>');
    background-size: 30px;
    background-repeat: no-repeat;
    background-position: center;
}

.sort-words-info-title {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: #444;
}

.sort-words-info-text {
    color: #666;
    line-height: 1.6;
}

/* Content Section */
.sort-words-content-section {
    margin-bottom: 60px;
}

.sort-words-content-wrapper {
    max-width: 800px;
    margin: 0 auto;
}

.sort-words-content-text {
    margin-bottom: 20px;
    color: #555;
    font-size: 1.1rem;
    line-height: 1.7;
}

.sort-words-feature-highlight {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    align-items: center;
    margin: 40px 0;
    background: #f9f9ff;
    padding: 30px;
    border-radius: 12px;
}

.sort-words-feature-desc {
    flex: 1;
    min-width: 300px;
}

.sort-words-feature-visual {
    flex: 1;
    min-width: 300px;
    height: 200px;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 400 200"><rect x="50" y="30" width="300" height="40" fill="%236e8efb" rx="5"/><rect x="50" y="90" width="300" height="40" fill="%23a777e3" rx="5"/><rect x="50" y="150" width="300" height="40" fill="%236e8efb" rx="5"/><text x="200" y="55" fill="white" font-family="Arial" font-size="14" text-anchor="middle">Apple Banana Cherry</text><text x="200" y="115" fill="white" font-family="Arial" font-size="14" text-anchor="middle">Cherry Banana Apple</text><text x="200" y="175" fill="white" font-family="Arial" font-size="14" text-anchor="middle">No duplicates</text></svg>') center no-repeat;
}

.sort-words-feature-title {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #444;
}

.sort-words-feature-text {
    margin-bottom: 15px;
    color: #555;
}

.sort-words-feature-list {
    padding-left: 20px;
    color: #555;
}

.sort-words-feature-list li {
    margin-bottom: 8px;
}

.sort-words-related-tool {
    background: #f0f4ff;
    padding: 20px;
    border-radius: 8px;
    margin-top: 40px;
    text-align: center;
}

.sort-words-related-title {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: #444;
}

.sort-words-related-text {
    color: #555;
}

.sort-words-related-link {
    color: #6e8efb;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s;
}

.sort-words-related-link:hover {
    color: #a777e3;
    text-decoration: underline;
}

/* FAQ Section */
.sort-words-faq-section {
    margin-bottom: 60px;
}

.sort-words-accordion {
    max-width: 800px;
    margin: 0 auto;
}

.sort-words-accordion-item {
    margin-bottom: 15px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.sort-words-accordion-btn {
    width: 100%;
    padding: 18px 20px;
    background: white;
    border: none;
    text-align: left;
    font-size: 1.1rem;
    font-weight: 600;
    color: #444;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.2s;
}

.sort-words-accordion-btn:hover {
    background-color: #f9f9f9;
}

.sort-words-accordion-icon {
    display: inline-block;
    width: 16px;
    height: 16px;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%236e8efb"><path d="M7.41 8.59L12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z"/></svg>') center no-repeat;
    transition: transform 0.3s;
}

.sort-words-accordion-btn.active .sort-words-accordion-icon {
    transform: rotate(180deg);
}

.sort-words-accordion-content {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, padding 0.3s ease;
    background-color: white;
}

.sort-words-accordion-content.show {
    padding: 20px;
    max-height: 500px;
}

.sort-words-accordion-content p {
    margin: 0;
    color: #555;
    line-height: 1.6;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .sort-words-title {
        font-size: 2.2rem;
    }
    
    .sort-words-subtitle {
        font-size: 1.2rem;
    }
    
    .sort-words-tool-wrapper {
        flex-direction: column;
    }
    
    .sort-words-info-box {
        min-width: 100%;
    }
    
    .sort-words-feature-highlight {
        flex-direction: column;
    }
    
    .sort-words-feature-desc, 
    .sort-words-feature-visual {
        min-width: 100%;
    }
}

@media (max-width: 480px) {
    .sort-words-hero {
        padding: 30px 20px;
    }
    
    .sort-words-title {
        font-size: 1.8rem;
    }
    
    .sort-words-options {
        flex-direction: column;
        gap: 15px;
    }
    
    .sort-words-option-group {
        min-width: 100%;
    }
}