body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 20px;
    background-color: #f8f9fa; /* Lighter background */
    color: #343a40; /* Darker text */
}

.container {
    max-width: 850px;
    margin: 20px auto;
    padding: 30px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

h1 {
    text-align: center;
    color: #007bff; /* Blue heading */
    margin-bottom: 10px;
}

h1 i {
    margin-right: 10px;
}

p {
    text-align: center;
    color: #6c757d; /* Gray description */
    margin-bottom: 30px;
    font-size: 1.05rem;
}

.input-area {
    margin-bottom: 30px;
}

textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #ced4da;
    border-radius: 5px;
    box-sizing: border-box;
    font-size: 1rem;
    resize: vertical;
    min-height: 200px; /* Larger input area */
    background-color: #fff;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.06);
}

textarea:focus {
    border-color: #80bdff;
    outline: 0;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}


.stats-area {
    background-color: #e9ecef; /* Light gray background for stats */
    padding: 25px;
    border-radius: 8px;
    margin-bottom: 25px;
}

.stats-area h2 {
    text-align: center;
    margin-top: 0;
    margin-bottom: 25px;
    color: #495057;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); /* Responsive grid */
    gap: 20px;
    margin-bottom: 25px;
}

.stat-item {
    background-color: #fff;
    padding: 15px;
    border-radius: 5px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column; /* Stack label and value */
    align-items: center; /* Center content */
    text-align: center;
}

.stat-label {
    font-weight: 500;
    color: #6c757d;
    margin-bottom: 8px;
    font-size: 0.9rem;
}

.stat-value {
    font-size: 1.5rem; /* Larger value */
    font-weight: 700;
    color: #007bff;
}

#btn-clear {
    display: block; /* Make button block level */
    margin: 0 auto; /* Center the button */
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    background-color: #dc3545; /* Red clear button */
    color: white;
    cursor: pointer;
    font-size: 0.95rem;
    transition: background-color 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

#btn-clear:hover {
    background-color: #c82333;
}


.back-link {
    text-align: center;
    margin-top: 30px;
}

.back-link a {
    color: #007bff;
    text-decoration: none;
    font-weight: 500;
}

.back-link a:hover {
    text-decoration: underline;
}