body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
    margin: 0;
    background-color: #f0f4f8;
    color: #333;
    line-height: 1.5;
}

*, *::before, *::after {
    box-sizing: border-box;
}

main {
    max-width: 900px;
    margin: 2rem auto;
    padding: 0 1rem;
}

h1, h2 {
    color: #102a43;
}

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

body {
    font-family: Arial, sans-serif;
    background: #f0f4f8;
    color: #333;
    line-height: 1.5;
}

.navbar {
    display: flex;
    justify-content: space-around;
    align-items: center;
    background: #1e90ff;
    padding: 0.5rem 1rem;
    color: white;
}
.logo {
    border-radius: 50%;
}

img {
    width: 50px;
    height: 50px;
}

ul.nav-links {
    align-items: center;
}

.navbar .nav-links {
    list-style: none;
    display: flex;
    gap: 1rem;
}

.navbar .nav-links li a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    align-items: center;
}

.navbar .nav-links li a:hover {
    text-decoration: underline;
}

header {
    text-align: center;
    padding: 1.5rem 1rem;
}

header h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

main {
    max-width: 800px;
    margin: auto;
    padding: 1rem;
}

form {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

form input[type="text"] {
    flex: 1;
    padding: 0.5rem;
    font-size: 1rem;
}

form button {
    padding: 0.5rem 1rem;
    background-color: #1e90ff;
    color: white;
    border: none;
    cursor: pointer;
    font-weight: bold;
}

form button:hover {
    background-color: #187bcd;
}

section {
    margin-bottom: 2rem;
}

section h2 {
    margin-bottom: 0.5rem;
}

footer {
    background-color: #1e90ff;
    color: white;
    text-align: center;
    padding: 1rem 0;
    font-size: 0.9rem;
}


header {
    background-color: #2c3e50;
    color: #ecf0f1;
    padding: 1rem 2rem;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

header h1 {
    color: #fff;
    margin: 0;
    font-size: 1.75rem;
}

header a {
    position: absolute;
    left: 2rem;
    color: #ecf0f1;
    text-decoration: none;
    font-size: 1rem;
    transition: color 0.3s ease;
}

header a:hover {
    color: #3498db;
}

#searchForm {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

#cityInput {
    flex-grow: 1;
    padding: 0.75rem;
    font-size: 1rem;
    border: 1px solid #ccc;
    border-radius: 5px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

#cityInput:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 5px rgba(52, 152, 219, 0.5);
}

#searchForm button {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#searchForm button:hover {
    background-color: #2980b9;
}

section {
    background-color: #fff;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
}

section h2 {
    margin-top: 0;
    border-bottom: 2px solid #f0f4f8;
    padding-bottom: 0.5rem;
}

#historyList {
    list-style: none;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

#historyList li {
    background-color: #e0e0e0;
    padding: 0.5rem 1rem;
    border-radius: 15px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#historyList li:hover {
    background-color: #c7c7c7;
}


#weatherDetail {
    background-color: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

#weatherDetail h2 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

#weatherDetail .temperature {
    font-size: 4rem;
    font-weight: bold;
    color: #2c3e50;
}

#weatherDetail .description {
    font-size: 1.5rem;
    color: #555;
    text-transform: capitalize;
}
#clearHistoryBtn {
  margin: 10px 0;
  padding: 5px 10px;
  background-color: #e74c3c;
  border: none;
  color: white;
  cursor: pointer;
  border-radius: 5px;
  transition: background 0.3s;
}

#clearHistoryBtn:hover {
  background-color: #c0392b;
}
