@charset "UTF-8";
* {
  box-sizing: border-box;
}

body {
  font-family: "Roboto", sans-serif;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

li, a, button {
  font-weight: 500;
  font-size: 20px;
  color: #edf0f1;
  text-decoration: none;
}

header {
  display: block;
  background-color: #222;
  padding: 0.8rem 0;
  color: white;
  font-family: "Roboto", sans-serif;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  max-width: 1200px;
  padding: 0 16px;
  margin: 0 auto;
}

#news-name {
  font-size: 1.5rem;
  font-weight: bold;
  letter-spacing: 1px;
  margin: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 1.5rem; /* spacing between items */
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-links li {
  display: inline-block;
  padding: 0px 20px;
}
.nav-links li a {
  transition: all 0.3s ease 0s;
  font-weight: 700;
}
.nav-links li a:hover {
  color: rgba(0, 136, 169, 0.8);
}

.menu-toggle {
  display: none;
}

.nav-links a {
  color: white;
  text-decoration: none;
  font-size: 1rem;
}

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

.nav-links.active {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 64px;
  right: 16px;
  background: #24252a;
  border-radius: 12px;
  padding: 10px 12px;
  gap: 8px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  z-index: 1001;
}

.accBtn {
  background-color: rgb(0, 136, 169);
  color: white;
  border: none;
  padding: 0.4rem 0.9rem;
  border-radius: 20px;
  cursor: pointer;
  font-size: 0.9rem;
  transition: background 0.3s;
}
.accBtn:hover {
  background-color: rgba(0, 136, 169, 0.8);
}

.auth {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: #fff;
  padding: 2em;
  border-radius: 10px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  width: 90%;
  max-width: 400px;
  z-index: 999;
}

fieldset {
  display: flex;
  flex-direction: column;
  margin: 2em 0;
  padding: 1em 2em;
  border: none;
  border-radius: 6px;
  min-width: 200px;
}
fieldset label {
  display: block;
  margin-top: 1em;
  font-size: large;
  font-weight: bold;
}
fieldset label:first-of-type {
  margin-top: 0;
}
fieldset .form-header {
  margin: auto;
  margin-bottom: 1em;
}

@media (min-width: 769px) {
  nav {
    flex: 1 1 auto;
  }
}
@media (max-width: 768px) {
  header {
    justify-content: space-between;
    padding: 0.8rem 1rem;
    gap: 1rem;
  }
  #news-name {
    margin-right: auto;
  }
  .menu-toggle {
    display: block;
    margin-left: 0.75rem;
    font-size: 1.25rem;
  }
  nav {
    flex: 0 0 auto;
    width: auto;
  }
  .nav-links {
    display: none;
    position: absolute;
    top: 60px;
    left: 1rem;
    right: 1rem;
    background: #222;
    flex-direction: column;
    gap: 1rem;
    padding: 1rem;
  }
  .nav-links.active {
    display: flex;
    z-index: 1000;
  }
}
input[type=email], input[type=password], input[type=submit], input[type=text] {
  width: 100%;
  padding: 12px;
  margin: 10px 0;
  box-sizing: border-box;
  font-size: 1em;
}

input[type=submit] {
  background-color: #24252a;
  color: #edf0f1;
  font-weight: bold;
}

#btn_login, #btn_signup {
  display: block;
  margin: 20px auto;
  padding: 10px;
  max-width: 100px;
}

.search-bar {
  display: flex;
  align-items: center;
  background-color: white;
  border-radius: 20px;
  padding: 0.2rem 0.6rem;
  gap: 0.3rem;
}
.search-bar input[type=text] {
  border: none;
  outline: none;
  padding: 0.3rem 0.5rem;
  border-radius: 20px;
  width: 160px;
  font-size: 0.9rem;
}
.search-bar .search-btn {
  border: none;
  background: none;
  color: #333;
  cursor: pointer;
  font-size: 1rem;
  background-color: #24252a;
  border-radius: 10px;
}
.search-bar .search-btn:hover {
  background-color: rgba(0, 136, 169, 0.8);
}
.search-bar .search-btn i {
  color: #fff;
  font-size: 14px;
  line-height: 1;
}

.alert {
  display: flex;
  width: 100%;
  justify-content: space-between;
  align-items: center;
  padding: 12px;
}
.alert .close {
  background: transparent;
  border: 0;
  cursor: pointer;
  font-size: 1.5rem;
  color: black;
  font-weight: 300;
}
.alert.alert-danger {
  background-color: rgba(245, 118, 118, 0.8);
}
.alert.alert-success {
  background-color: rgba(135, 252, 135, 0.8);
}

#intro {
  font-size: 24px;
  font-weight: bold;
}

.page-container {
  max-width: 1200px; /* keep it narrow and centered */
  margin: 0 auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  min-height: 100vh; /* take up full viewport height */
  box-sizing: border-box;
}

.saved-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem clamp(1rem, 3vw, 2rem);
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

/* ---------- Articles Grid ---------- */
.articles {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: clamp(0.8rem, 2vw, 1.25rem);
  align-items: start;
  margin-top: 1rem;
}

.articles article,
.article-card {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
  padding: 1rem 1rem 0.9rem;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  display: flex;
  flex-direction: column;
  min-height: 120px;
}
.articles article:hover, .articles article:focus-within,
.article-card:hover,
.article-card:focus-within {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
}

/* Title */
.article-title,
.articles article h2 {
  margin: 0 0 0.6rem;
  font-size: clamp(1.05rem, 2.2vw, 1.2rem);
  line-height: 1.25;
}
.article-title a,
.articles article h2 a {
  color: #111;
  text-decoration: none;
  display: inline-block;
  /* Two-line clamp for long headlines */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.article-title a:hover, .article-title a:focus,
.articles article h2 a:hover,
.articles article h2 a:focus {
  text-decoration: underline;
  outline: none;
}

/* Meta row: date + source badge */
.article-meta,
.articles article .article-meta {
  margin-top: auto; /* push meta to bottom for consistent height */
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  padding-top: 0.65rem;
}

.published {
  font-size: 0.85rem;
  color: #666;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* “Source” as a subtle chip */
.source-badge {
  font-size: 0.75rem;
  font-weight: 600;
  color: #0a2b33;
  background: rgba(0, 136, 169, 0.12);
  border: 1px solid rgba(0, 136, 169, 0.28);
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  max-width: 60%;
  text-align: right;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ---------- Pagination ---------- */
.pagination {
  margin: 1.5rem 0 2.5rem;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.6rem;
}
.pagination a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 98px;
  padding: 0.55rem 0.9rem;
  border-radius: 999px;
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: #fff;
  color: #111;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.08s ease;
}
.pagination a:hover {
  background: #f6f8f9;
  border-color: rgba(0, 0, 0, 0.16);
}
.pagination a:active {
  transform: translateY(1px);
}

@media (max-width: 480px) {
  .articles {
    grid-template-columns: 1fr;
    gap: 0.9rem;
  }
  .article-title,
  .articles article h2 {
    font-size: 1.05rem;
  }
  .published {
    font-size: 0.8rem;
  }
  .source-badge {
    max-width: 50%;
  }
}
/* ---------- Daily Debrief (Hero Slider) ---------- */
.daily-debrief {
  max-width: 100%;
  margin: 1rem 0;
  padding: clamp(1rem, 2vw, 1.5rem);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
  z-index: 1;
}

.debrief-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.6rem;
  padding: 1rem;
}
.debrief-header h2 {
  margin: 0;
  font-size: clamp(1.25rem, 3vw, 1.6rem);
  letter-spacing: 0.2px;
  color: #fffefe;
}

.debrief-controls {
  display: flex;
  gap: 0.4rem;
}
.debrief-controls .debrief-btn {
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: #fff;
  border-radius: 10px;
  width: 38px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.08s ease;
}
.debrief-controls .debrief-btn:hover {
  background: #f4f6f7;
}
.debrief-controls .debrief-btn:active {
  transform: translateY(1px);
}
.debrief-controls .debrief-btn i {
  font-size: 14px;
  color: #111;
}

.debrief-track {
  position: relative;
  overflow: hidden;
  min-height: clamp(120px, 10vw, 160px);
}

.debrief-slide {
  /* stacked slides; we fade/slide the active one in */
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transform: translateY(6px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.debrief-slide.is-active {
  position: relative; /* becomes the only visible one */
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.debrief-link {
  display: block;
  width: 100%;
  padding: clamp(0.5rem, 1.6vw, 0.9rem);
  border-radius: 12px;
  text-decoration: none;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.03), rgba(0, 0, 0, 0));
}

.debrief-title {
  margin: 0 0 0.5rem 0;
  font-size: clamp(1.05rem, 2.5vw, 1.35rem);
  line-height: 1.25;
  color: #111;
  /* clamp to 3 lines */
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.debrief-meta {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  justify-content: space-between;
  font-size: 0.9rem;
}
.debrief-meta .published {
  color: #666;
}

.debrief-dots {
  display: flex;
  justify-content: center;
  gap: 0.35rem;
  margin-top: 0.6rem;
}
.debrief-dots .debrief-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  border: 0;
  background: rgba(0, 0, 0, 0.2);
  cursor: pointer;
  transition: transform 0.1s ease, background 0.15s ease;
}
.debrief-dots .debrief-dot.is-active {
  background: rgb(0, 136, 169);
  transform: scale(1.2);
}

/* Make the debrief section visually larger than cards */
.daily-debrief + .articles {
  margin-top: clamp(0.6rem, 1.5vw, 1rem);
}

/* small screens */
@media (max-width: 480px) {
  .debrief-track {
    min-height: 130px;
  }
}
.dropdown .user-btn {
  background: none;
  border-style: solid;
}
.dropdown .user-btn:hover {
  background-color: rgb(0, 136, 169);
  cursor: pointer;
}
.dropdown .user-btn:active {
  opacity: 0.8;
}

.dropdown {
  position: relative;
  display: inline-block;
}
.dropdown a {
  display: block;
  color: rgb(255, 255, 255);
  text-decoration: none;
  padding: 10px 15px;
}
.dropdown .content {
  display: none;
  position: absolute;
  top: 100%;
  right: 0%;
  background-color: #24252a;
  min-width: 100px;
  border: 1px solid white;
}
.dropdown .content.active {
  display: block;
}

.fa-trash-can {
  background: none;
  border: none;
  -webkit-appearance: none;
     -moz-appearance: none;
          appearance: none;
  color: #24252a;
  font-size: 1.2rem;
  transition: transform 0.2s ease-in-out;
}
.fa-trash-can:hover {
  color: rgb(0, 136, 169);
  transform: scale(1.15);
}

.fa-heart {
  font-size: 1.2rem;
  transition: transform 0.2s ease-in-out;
  color: #24252a;
}
.fa-heart:hover {
  color: red;
  transform: scale(1.15);
}
.fa-heart:active {
  opacity: 0.6;
}

.source-badge {
  margin-right: 12px;
}

.save-article, .delete-article {
  border: none;
  background: none;
}

#flash-container {
  width: 100%;
  display: flex;
  justify-content: center;
  position: relative;
  z-index: 10;
}

.flash-message {
  width: 100%;
  padding: 10px 20px;
  color: black;
  font-weight: 500;
  animation: slideDown 0.3s ease;
}
.flash-message.success {
  background-color: rgba(135, 252, 135, 0.8);
}
.flash-message.error {
  background-color: rgba(245, 118, 118, 0.8);
}/*# sourceMappingURL=styles.css.map */