/* Keyword Density Checker Specific Styles */
.input-section {
    padding: 25px;
    border-bottom: 1px solid #eee;
}

.tab-buttons {
    display: flex;
    margin-bottom: 20px;
    border-radius: 8px;
    overflow: hidden;
    background: #f1f2f6;
}

.tab-btn {
    flex: 1;
    padding: 12px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-weight: 600;
    color: #2d3436;
    transition: all 0.3s ease;
    text-align: center;
}

.tab-btn.active {
    background: #6c5ce7;
    color: white;
}

.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2d3436;
}

.input-field {
    width: 100%;
    padding: 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: border 0.3s;
}

.input-field:focus {
    border-color: #6c5ce7;
    outline: none;
}

textarea.input-field {
    min-height: 150px;
    resize: vertical;
}

.checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 20px;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.checkbox-item input {
    width: 18px;
    height: 18px;
    accent-color: #6c5ce7;
}

.button-group {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.btn {
    color: white;
    border: none;
    padding: 15px 25px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex: 1;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.btn:active {
    transform: translateY(0);
}

.btn i {
    font-size: 1.1rem;
}

.analyze-btn {
    background: #6c5ce7;
}

.analyze-btn:hover {
    background: #5a4bd6;
}

.copy-btn {
    background: #0984e3;
}

.copy-btn:hover {
    background: #0877c4;
}

.clear-btn {
    background: #d63031;
}

.clear-btn:hover {
    background: #c23616;
}

.result-buttons {
    display: flex;
    gap: 10px;
}

.result-buttons .btn {
    padding: 10px 15px;
}

.results-section {
    padding: 25px;
    display: none;
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
}

.results-title {
    font-size: 1.5rem;
    color: #6c5ce7;
}

.keyword-stats {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.stat-card {
    flex: 1;
    min-width: 150px;
    background: white;
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.stat-card h3 {
    font-size: 0.9rem;
    color: #7f8c8d;
    margin-bottom: 5px;
}

.stat-card p {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2d3436;
}

.total-words {
    border-left: 4px solid #6c5ce7;
}

.unique-keywords {
    border-left: 4px solid #00b894;
}

.keyword-density {
    border-left: 4px solid #fd79a8;
}

.recommended-density {
    border-left: 4px solid #fdcb6e;
}

.keyword-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    border-radius: 10px;
    overflow: hidden;
}

.keyword-table th {
    background: #6c5ce7;
    color: white;
    padding: 15px;
    text-align: left;
}

.keyword-table td {
    padding: 12px 15px;
    border-bottom: 1px solid #eee;
}

.keyword-table tr:nth-child(even) {
    background: #f8f9fa;
}

.keyword-table tr:hover {
    background: #f1f2f6;
}

.density-bar {
    height: 8px;
    background: #dfe6e9;
    border-radius: 4px;
    margin-top: 5px;
    overflow: hidden;
}

.density-fill {
    height: 100%;
    border-radius: 4px;
}

.info-section {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 10px;
    margin-top: 30px;
}

.info-title {
    font-size: 1.2rem;
    color: #6c5ce7;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.info-list {
    list-style-type: none;
}

.info-list li {
    margin-bottom: 10px;
    padding-left: 25px;
    position: relative;
}

.info-list li:before {
    content: "•";
    color: #fd79a8;
    font-size: 1.5rem;
    position: absolute;
    left: 5px;
    top: -5px;
}

.loading {
    display: none;
    text-align: center;
    padding: 20px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border-top-color: #6c5ce7;
    animation: spin 1s ease-in-out infinite;
    margin: 0 auto 15px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.error-message {
    color: #e74c3c;
    background: #fadbd8;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: none;
}

@media (max-width: 768px) {
    .stat-card {
        min-width: calc(50% - 8px);
    }
    
    .keyword-table {
        font-size: 0.9rem;
    }
    
    .keyword-table th, .keyword-table td {
        padding: 10px;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .input-section, .results-section {
        padding: 20px 15px;
    }
    
    .tab-buttons {
        flex-direction: column;
    }
    
    .tab-btn {
        padding: 10px;
    }
    
    .checkbox-group {
        flex-direction: column;
        gap: 10px;
    }
    
    .stat-card {
        min-width: 100%;
    }
    
    .result-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .result-buttons .btn {
        width: 100%;
    }
}