* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #f5f5f5;
    min-height: 100vh;
    padding: 0;
    margin: 0;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    background: white;
    padding: 2rem;
    min-height: 100vh;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.05);
}

@media (max-width: 768px) {
    .container {
        padding: 1rem;
        box-shadow: none;
    }
}

h1 {
    font-size: 3rem;
    color: #2a2a2a;
    margin-bottom: 20px;
    font-weight: 700;
}

.subtitle {
    font-size: 1.5rem;
    color: #666;
    margin-bottom: 40px;
}

.description {
    font-size: 1.1rem;
    color: #555;
    margin-bottom: 30px;
    line-height: 1.8;
}

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 40px;
    text-align: left;
}

.feature {
    background: #fafafa;
    padding: 20px;
    transition: box-shadow 0.3s ease, transform 0.3s ease;
    text-decoration: none;
    color: inherit;
    display: block;
}

.feature:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.feature h3 {
    color: #2a2a2a;
    margin-bottom: 10px;
    font-size: 1.2rem;
}

.feature p {
    color: #666;
    font-size: 0.95rem;
}

/* Tool page styles */
.tool-header {
    padding: 1rem 0;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #e0e0e0;
}

.tool-header-content {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo-link {
    font-size: 1.2rem;
    font-weight: 700;
    color: #4a90e2;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.logo-link:hover {
    opacity: 0.8;
}

.tool-header h1 {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
    color: #333;
}

/* Mobile optimization */
@media (max-width: 768px) {
    .tool-header {
        padding: 0.75rem 0;
        margin-bottom: 1rem;
    }

    .tool-header h1 {
        font-size: 1.2rem;
    }

    .logo-link {
        font-size: 1rem;
    }
}

.status {
    margin-top: 40px;
    padding: 20px;
    background: #e8e8e8;
    border-left: 3px solid #999;
}

.status h2 {
    color: #2a2a2a;
    margin-bottom: 10px;
}

.status p {
    color: #555;
}

/* SEO content styles */
.seo-content {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid #e0e0e0;
    text-align: left;
}

.seo-content h2 {
    font-size: 1.8rem;
    color: #2a2a2a;
    margin-bottom: 20px;
    font-weight: 600;
}

.seo-content h3 {
    font-size: 1.4rem;
    color: #333;
    margin-top: 30px;
    margin-bottom: 15px;
    font-weight: 600;
}

.seo-content p {
    font-size: 1rem;
    color: #555;
    line-height: 1.8;
    margin-bottom: 20px;
}

.seo-content ul {
    margin-left: 20px;
    margin-bottom: 20px;
}

.seo-content ul li {
    font-size: 1rem;
    color: #555;
    line-height: 1.8;
    margin-bottom: 10px;
}

main {
    margin-bottom: 40px;
}

noscript p {
    background: #fff3cd;
    border: 1px solid #ffc107;
    color: #856404;
    padding: 15px;
    border-radius: 4px;
    text-align: center;
}

/* API page and contact form */
.api-page h2 {
    font-size: 1.35rem;
    color: #2a2a2a;
    margin-bottom: 0.75rem;
}

.api-intro {
    margin-bottom: 2.5rem;
}

.api-intro p {
    margin-bottom: 0.75rem;
    color: #444;
}

.api-badge {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    margin-bottom: 0.75rem;
    border-radius: 999px;
    background: #fff4d6;
    color: #7a5800;
    font-size: 0.85rem;
    font-weight: 600;
}

.api-features {
    margin: 0 0 1rem 1.25rem;
    color: #444;
}

.api-features li {
    margin-bottom: 0.35rem;
}

.api-features code {
    padding: 0.1rem 0.35rem;
    border-radius: 3px;
    background: #f0f3f7;
    font-size: 0.85rem;
    color: #2a5f9e;
}

.contact {
    padding-top: 1.5rem;
    border-top: 1px solid #e0e0e0;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-field {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.form-field label {
    font-size: 0.9rem;
    font-weight: 500;
    color: #333;
}

.form-field input[type="text"],
.form-field input[type="email"],
.form-field input[type="tel"],
.form-field select,
.form-field textarea {
    width: 100%;
    padding: 0.6rem 0.75rem;
    font: inherit;
    font-size: 0.95rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #fff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-field textarea {
    resize: vertical;
    min-height: 140px;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
    outline: none;
    border-color: #4a90e2;
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.2);
}

.form-field.has-error input,
.form-field.has-error select,
.form-field.has-error textarea {
    border-color: #e44;
}

.form-error {
    font-size: 0.85rem;
    color: #c33;
}

.required {
    color: #e44;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-weight: 400 !important;
    font-size: 0.9rem;
    color: #555 !important;
    cursor: pointer;
}

.checkbox-label input {
    margin-top: 0.3rem;
    flex-shrink: 0;
}

.form-hint {
    font-size: 0.85rem;
    color: #888;
}

.form-hp {
    position: absolute;
    left: -10000px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.form-submit {
    align-self: flex-start;
    padding: 0.875rem 2.5rem;
    font-size: 1rem;
    font-weight: 600;
    color: #fff;
    background-color: #4a90e2;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.form-submit:hover {
    background-color: #357abd;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(74, 144, 226, 0.3);
}

.form-notice {
    padding: 1rem;
    margin-bottom: 1.25rem;
    border: 1px solid;
    border-left-width: 4px;
    border-radius: 4px;
    font-size: 0.95rem;
}

.form-notice-success {
    background-color: #effaf1;
    border-color: #bfe5c6;
    border-left-color: #2e9e4a;
    color: #1f6e33;
}

.form-notice-error {
    background-color: #fee;
    border-color: #fcc;
    border-left-color: #e44;
    color: #c33;
}

@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
    }

    .form-submit {
        width: 100%;
        align-self: stretch;
    }
}

/* 404 page */
.not-found {
    padding: 2rem 0;
}

.not-found-code {
    font-size: 5rem;
    font-weight: 800;
    line-height: 1;
    color: #4a90e2;
}

.not-found h1 {
    font-size: 1.8rem;
    margin: 0.5rem 0 0.75rem;
}

.not-found-text {
    color: #555;
    max-width: 600px;
}

.not-found .features {
    margin-top: 1.5rem;
}

.not-found-home {
    display: inline-block;
    margin-top: 2rem;
    padding: 0.75rem 2rem;
    font-weight: 600;
    color: #fff;
    background: #4a90e2;
    border-radius: 4px;
    text-decoration: none;
}

.not-found-home:hover {
    background: #357abd;
}

@media (max-width: 768px) {
    .not-found-code {
        font-size: 3.5rem;
    }

    .not-found h1 {
        font-size: 1.4rem;
    }
}
