body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
    color: #333;
    line-height: 1.6;
}

header {
    background-color: #333;
    color: #fff;
    padding: 1rem 0;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

main {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.formatter-container {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 20px;
    margin: 20px 0;
}

.input-section, .output-section {
    flex: 1;
    min-width: 300px;
    background-color: white;
    border-radius: 5px;
    padding: 15px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.input-section h2, .output-section h2 {
    margin-top: 0;
    color: #444;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

textarea#jsonInput {
    width: 100%;
    height: 300px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: monospace;
    font-size: 14px;
    resize: vertical;
    box-sizing: border-box;
}

pre#jsonOutput {
    width: 100%;
    height: 300px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: #f9f9f9;
    overflow: auto;
    font-family: monospace;
    font-size: 14px;
    white-space: pre-wrap;
    box-sizing: border-box;
}

.button-group {
    margin-bottom: 15px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.action-button {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background-color 0.3s;
}

.action-button:hover {
    background-color: #0056b3;
}

.action-button.secondary {
    background-color: #6c757d;
}

.action-button.secondary:hover {
    background-color: #5a6268;
}

.info-section {
    background-color: white;
    border-radius: 5px;
    padding: 20px;
    margin: 20px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.info-section h2 {
    color: #333;
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
}

.info-section h3 {
    color: #444;
    margin-top: 20px;
}

.info-section ul, .info-section ol {
    padding-left: 20px;
}

.info-section li {
    margin-bottom: 8px;
}

.note {
    background-color: #f8f9fa;
    border-left: 4px solid #007bff;
    padding: 15px;
    margin-top: 20px;
    border-radius: 0 4px 4px 0;
}

.note h4 {
    margin-top: 0;
    color: #007bff;
}

/* Ad Container Styling */
.ad-container {
    width: 100%;
    max-width: 800px;
    margin: 20px auto;
    padding: 15px;
    background-color: white;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    text-align: center;
    overflow: hidden;
    min-height: 100px;
}

.ad-bottom {
    margin-top: 30px;
    background-color: #f9f9f9;
    border-top: 3px solid #007bff;
}

footer {
    text-align: center;
    padding: 1rem 0;
    background-color: #333;
    color: #fff;
    margin-top: 30px;
}

footer a {
    color: #fff;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

/* Error message styling */
.error-message {
    color: #dc3545;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    padding: 10px;
    margin-top: 10px;
    display: none;
}

/* Success message styling */
.success-message {
    color: #28a745;
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 4px;
    padding: 10px;
    margin-top: 10px;
    display: none;
}

/* History Section Styles */
.history-section {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 20px;
    margin: 20px 0;
    border-left: 4px solid #4a90e2;
    animation: highlight-section 2s ease-in-out;
}

@keyframes highlight-section {
    0% { box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); }
    50% { box-shadow: 0 0 20px rgba(74, 144, 226, 0.5); }
    100% { box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); }
}

.history-section h2 {
    color: #333;
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
}

.history-section h2::before {
    content: "⏱️";
    margin-right: 10px;
    font-size: 1.2rem;
}

.history-info {
    color: #666;
    margin-bottom: 15px;
    font-size: 0.95rem;
    background-color: #f0f7ff;
    padding: 10px;
    border-radius: 4px;
    border-left: 3px solid #4a90e2;
}

.history-controls {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 15px;
}

.history-container {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 10px;
    background-color: #f9f9f9;
}

.history-item {
    padding: 12px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: white;
    margin-bottom: 8px;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.history-item:hover {
    background-color: #f0f7ff;
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.history-item:last-child {
    border-bottom: none;
}

.history-item-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
}

.history-timestamp {
    color: #666;
    font-size: 0.85rem;
}

.history-preview {
    color: #333;
    font-family: monospace;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 0.9rem;
    padding: 4px;
    background-color: #f5f5f5;
    border-radius: 3px;
}

.empty-history {
    color: #999;
    text-align: center;
    padding: 20px;
    font-style: italic;
}

@media (max-width: 768px) {
    .formatter-container {
        flex-direction: column;
    }
    
    .history-container {
        max-height: 200px;
    }
    
    .button-group {
        flex-wrap: wrap;
    }
} 
