/* ===========================
   Common Styles
   =========================== */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: #f5f5f5;
}

/* ===========================
   News Aggregator Page Styles
   =========================== */
.container {
  max-width: 100%;
  padding: 0 15px;
  margin: 0 auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px auto;
  background-color: white;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

th,
td {
  border: 1px solid #ddd;
  padding: 12px;
  text-align: left;
  vertical-align: top;
}

th {
  background-color: #f8f9fa;
  font-weight: 600;
  color: #333;
  position: sticky;
  top: 0;
  z-index: 10;
}

tr:hover {
  background-color: #f9f9f9;
}

button {
  background-color: #4CAF50;
  border: none;
  color: white;
  padding: 8px 16px;
  text-align: center;
  text-decoration: none;
  display: inline-block;
  font-size: 14px;
  margin: 4px 2px;
  cursor: pointer;
  border-radius: 4px;
  transition: background-color 0.3s ease;
}

button:hover {
  background-color: #45a049;
}

td a {
  color: #333;
  text-decoration: none;
  transition: color 0.2s ease;
}

td a:hover {
  color: #007bff;
  text-decoration: underline;
}

/* Filter styles */
.filter-container {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
  padding: 15px;
  background-color: white;
  border-radius: 4px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.filter-container label {
  margin-right: 10px;
  font-size: 16px;
  font-weight: 500;
  color: #333;
}

.filter-container select {
  padding: 8px 12px;
  font-size: 14px;
  border: 1px solid #ddd;
  border-radius: 4px;
  background-color: #fff;
  color: #333;
  cursor: pointer;
  min-width: 200px;
}

.filter-container select:focus {
  outline: none;
  border-color: #007bff;
  box-shadow: 0 0 0 3px rgba(0,123,255,0.1);
}

/* Search box styles */
.input-group {
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  border-radius: 4px;
  overflow: hidden;
}

/* Instagram highlight section */
.instagram-highlight {
  margin-top: 10px;
  padding: 10px;
  background-color: #f8f9fa;
  border-left: 3px solid #007bff;
  border-radius: 4px;
  font-size: 13px;
}

.instagram-highlight strong {
  color: #333;
}

.instagram-highlight p {
  margin: 5px 0;
  color: #666;
}

.datetime-stamp {
  display: block;
  font-size: 12px;
  color: #999;
  font-weight: normal;
  margin-top: 5px;
}

.title-link {
  font-weight: bold;
  font-size: 16px;
  line-height: 1.4;
}

.title-link.highlight {
  color: #ff0000;
}

.title-link.normal {
  color: #333;
}

form {
  display: inline-block;
  margin: 0;
}

/* ===========================
   Login Page Styles
   =========================== */
body.login-page {
  background-color: #f8f9fa;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
}

.form-signin {
  width: 100%;
  max-width: 330px;
  padding: 15px;
  margin: auto;
}

.form-signin .checkbox {
  font-weight: 400;
}

.form-signin .form-control {
  position: relative;
  box-sizing: border-box;
  height: auto;
  padding: 10px;
  font-size: 16px;
}

.form-signin .form-control:focus {
  z-index: 2;
}

.form-signin input[type="text"],
.form-signin input[type="username"] {
  margin-bottom: -1px;
  border-bottom-right-radius: 0;
  border-bottom-left-radius: 0;
}

.form-signin input[type="password"] {
  margin-bottom: 10px;
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}

.form-signin .h3 {
  text-align: center;
  margin-bottom: 20px;
}

.form-signin .btn-primary {
  background-color: #007bff;
  border-color: #007bff;
  transition: background-color 0.3s ease;
}

.form-signin .btn-primary:hover {
  background-color: #0056b3;
  border-color: #0056b3;
}

/* ===========================
   Responsive Styles
   =========================== */
@media only screen and (max-width: 768px) {
  table {
    font-size: 14px;
  }

  th,
  td {
    padding: 8px;
  }

  .filter-container {
    flex-direction: column;
    align-items: flex-start;
  }

  .filter-container label {
    margin-bottom: 8px;
  }

  .filter-container select {
    width: 100%;
  }

  .title-link {
    font-size: 14px;
  }

  button {
    padding: 6px 12px;
    font-size: 13px;
  }
}

@media only screen and (max-width: 600px) {
  .container {
    padding: 0 10px;
  }

  table {
    font-size: 13px;
  }

  th,
  td {
    padding: 6px;
  }

  .form-signin {
    padding: 10px;
  }
}