@import "../cloudui_styling/colors.css";


.news-page {
  line-height: 1.6;
  color: var(--cloudui-copy, #344054);
  min-height: 100%;
  padding: 1.5rem clamp(1rem, 6vw, 15rem) 2rem;
  max-width: 80%;
  margin: 0 auto;
}

.news-header {
  border-bottom: 1px solid var(--cloudui-border);
  margin: 0 0 2rem;
  padding: 0 0 1.75rem;
  text-align: left;
}

.news-header h1 {
  color: #000;
  font-size: clamp(2rem, 3.5vw, 2.5rem);
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 0.55rem;
}

.news-header p {
  color: var(--cloudui-muted, #667085);
  font-size: 1.1rem;
  line-height: 1.55;
  margin: 0;
}

body:has(.news-page) .layout > main {
  background: var(--cloudui-off-white)
    url("../../images/auth-background-waves.png") center / cover no-repeat;
  padding-left: 0;
  width: 100%;
}

body:has(.news-page) .layout main > .container.pb-5 {
  height: 100%;
  margin: 0;
  max-width: none;
  min-height: 100%;
  padding: 0 !important;
  width: 100%;
}

body:has(.news-page) .layout main > .container.pb-5 > h2.asset-dark-blue {
  display: none;
}

body:has(.news-page) header {
  height: 65px;
}

body:has(.news-page) .layout main > .container.messages {
  height: auto !important;
  left: 10%;
  margin: 1rem 0 0;
  position: absolute;
  width: 80%;
  z-index: 10;
}

.news-item {
  margin: 1rem;
}

.news-card {
  background: var(--cloudui-white, #fff);
  border: 1px solid var(--cloudui-border, #e4e7ec);
  border-top: 3px solid var(--cloudui-blue, #075fa8);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(16, 24, 40, 0.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.news-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(16, 24, 40, 0.16);
}

@media (prefers-reduced-motion: reduce) {
  .news-card {
    transition: none;
  }

  .news-card:hover {
    transform: none;
  }
}

.thumbnail-container {
  width: 100%;
  padding-top: 66.67%; /* 3:2 aspect ratio */
  position: relative;
  overflow: hidden;
  background: #f7f9fc;
  border-bottom: 1px solid var(--cloudui-border, #e4e7ec);
}

.thumbnail-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.news-item-content {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 1.25rem 1.4rem 1.4rem;
}

.headline {
  display: block;
  color: var(--cloudui-heading, #101828);
  font-size: 1.35rem;
  font-weight: 600;
  line-height: 1.3;
  transition: color 0.2s ease;
}

.news-card:hover .headline {
  color: var(--cloudui-blue, #075fa8);
}

.news-item-body {
  color: var(--cloudui-muted, #667085);
  font-size: 1.05rem;
  line-height: 1.5;
  margin: 0.6rem 0 1.25rem;
}

.news-item-body p {
  margin: 0;
}

.news-item-footer {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem 0.75rem;
}

.news-item-footer .btn,
.news-item-footer .btn-flat {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--cloudui-blue, #075fa8);
  border-radius: 6px;
  color: var(--cloudui-blue, #075fa8);
  font-size: 0.95rem;
  font-weight: 600;
  height: auto;
  line-height: 1;
  padding: 0.5rem 1rem;
  text-transform: none;
  box-shadow: none;
  flex-shrink: 0;
  white-space: nowrap;
  transition:
    background 0.2s ease,
    color 0.2s ease;
}

.news-item-footer .btn:hover,
.news-item-footer .btn-flat:hover {
  background: var(--cloudui-blue, #075fa8);
  color: #fff;
}

.news-item-date {
  color: var(--cloudui-muted, #667085);
  font-weight: 400;
  font-size: 0.95rem;
  text-align: right;
  min-width: 0;
}

.pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.35rem;
  margin: 2rem 0 0;
  padding-left: 0;
}

.pagination li {
  border-radius: 6px;
  min-width: 36px;
  height: 36px;
  line-height: 36px;
  text-align: center;
}

.pagination li a {
  color: var(--cloudui-blue, #075fa8);
  display: block;
  height: 100%;
}

.pagination li.active {
  background-color: var(--cloudui-blue, #075fa8);
  color: #fff;
}

.pagination li.active a {
  color: #fff;
}

.pagination li.waves-effect:hover {
  background-color: rgba(7, 95, 168, 0.08);
}

.pagination li.disabled i {
  color: #c7ced2;
}

.pagination-ellipsis {
  color: var(--cloudui-muted, #667085);
}

@media (max-width: 600px) {
  .news-item {
    margin-bottom: 1.25rem;
  }

  .headline {
    font-size: 1.4rem;
  }

  .news-item-body {
    font-size: 1.15rem;
  }
}
