.seo-tool-container {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
background: #f9f9f9;
border: 1px solid #ddd;
border-radius: 8px;
padding: 20px;
max-width: 650px;
margin: 20px auto;
color: #333;
}
.seo-tool-container h3 {
margin-top: 0;
color: #23282d;
}
.seo-tool-field {
margin-bottom: 15px;
}
.seo-tool-field label {
display: block;
font-weight: bold;
margin-bottom: 5px;
font-size: 14px;
}
.seo-tool-field input, .seo-tool-field textarea {
width: 100%;
padding: 10px;
border: 1px solid #ccc;
border-radius: 4px;
box-sizing: border-box;
}
.seo-tool-field textarea {
height: 80px;
resize: vertical;
}
.seo-serp-preview {
background: #fff;
border: 1px solid #e1e1e1;
padding: 15px;
border-radius: 4px;
margin-top: 20px;
}
.serp-title {
color: #1a0dab;
font-size: 20px;
line-height: 1.3;
margin-bottom: 3px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
display: block;
text-decoration: none;
}
.serp-url {
color: #006621;
font-size: 14px;
line-height: 1.3;
margin-bottom: 3px;
display: block;
}
.serp-desc {
color: #545454;
font-size: 14px;
line-height: 1.4;
word-wrap: break-word;
}
.seo-counter {
font-size: 12px;
color: #666;
margin-top: 5px;
text-align: right;
}
.seo-btn {
background-color: #007cba;
color: white;
border: none;
padding: 10px 15px;
border-radius: 4px;
cursor: pointer;
font-weight: bold;
}
.seo-btn:hover {
background-color: #006ba1;
}
var updatePreview = function() {
var title = document.getElementById('seo-title-input').value;
var desc = document.getElementById('seo-desc-input').value;
if(title) document.getElementById('preview-title').innerText = title;
if(desc) document.getElementById('preview-desc').innerText = desc;
};