/* Grid view */

#articlesContainer {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    column-gap: 20px;
    row-gap: 30px;
    padding: 10px 0;
}

.article-entry {
    background: rgba(0, 0, 0, 0.4);
    border: 2px solid white;
    border-radius: 10px;
    padding: 16px;
    transition: 
        filter 0.3s ease, 
        background 0.3s ease,
        border-color 0.2s,
        color 0.2s,
        transform 0.15s;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content:start;
    height: 100%;
    word-break: normal;
    position: relative;
}

.article-entry:hover {
    background: rgba(255, 255, 255, 0.067);
    filter: brightness(1.1);
    border-color: #00ffff;
    transform: scale(1.03);
}

.article-entry:hover .labels-container .label:not(.tag) {
    border-color: #00ffff;
    transition: border-color 0.2s;
}

.article-entry:hover .article-title {
    color: #00ffff;
    transition: color 0.2s;
}

.article-title {
    font-size: 25px;
    color: white;
    margin-bottom: 5px;
    margin-top: 10px;
}

.article-subtitle {
    font-size: 17px;
    color: #aaa;
    margin-bottom: 15px;
}

.article-date {
    display: block;
    font-size: 14px;
    color: #aaa;
    margin-bottom: 10px;
    margin-top: 5px;
}

.article-image {
    aspect-ratio: 16 / 9;
    width: 100%;
    height: auto;
    object-fit: cover;
    border: 4px solid #00000053;
    border-radius: 10px;
    display: block;
}

.labels-container {
    display: flex;
    gap: 8px;
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
}

.labels-container.tags {
    position: static;
    justify-content: flex-start;
    gap: 6px;
    transform: none;
    flex-wrap: wrap-reverse;
    width: 100%;
    margin-top: auto;
    margin-bottom: 5px;
}

.label {
    border: #ffffff 2px solid;
    color: white;
    padding: 4px 12px;
    border-radius: 8px;
    font-size: 15px;
    text-align: center;
}

.label.new {
    background: #ff0055;
}

.label.official {
    background: #0055ff;
}

.label.tag {
    background: #222;
    border: 2px solid #888;
    color: #bbb;
    font-size: 14px;
    padding: 3px 10px;
    border-radius: 7px;
    transition: 
        background 0.2s,
        border-color 0.2s,
        color 0.2s,
        transform 0.15s;
    cursor: pointer;
}

.label.tag:hover {
    background: #444;
    border-color: #fff;
    color: #fff;
    transform: scale(1.05);
}

.label.tag.not-clickable {
    pointer-events: none;
    opacity: 0.6;
}

/* Full article view */

.full-article-detail {
  max-width: 700px;
  margin: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 15px;
  box-sizing: border-box;
  background: rgba(0, 0, 0, 0.4);
  border: 2px solid white;
  border-radius: 20px;
  font-size: 20px;
}

.full-article-title {
  text-align: center;
  font-size: 40px;
}

.full-article-metadata {
  display: flex;
  justify-content: space-between;
  color: #777;
}

.full-article-image {
    width: 100%;
    height: auto;
    border: 4px solid #00000053;
    border-radius: 20px;
    object-fit: cover;
}

.full-article-content {
  font-size: 16px;
  font-family: 'RobotoVariable', sans-serif;
  white-space: pre-line;
  list-style-position: inside;
}

.full-article-content > * {
    margin-left: 0;
    padding-left: 0;
    text-align: left;
}

.full-article-content a {
    color: #FF66CC;
    text-decoration: none;
    transition: color 0.2s;
}

.full-article-content a:hover {
    color: #00FFFF;
    text-decoration: underline;
}

.full-article-content img {
    display: block;
    margin: 20px auto;
    margin-bottom: 0px;
    max-width: 700px;
    width: 100%;
    height: auto;
    border: 4px solid #00000053;
    border-radius: 20px;
    object-fit: cover;
}

.full-article-content ul,
.full-article-content ol,
.full-article-content li {
    white-space: normal;
}

.full-article-content ul,
.full-article-content ol {
    margin-left: 32px;
    padding-left: 24px;
    list-style-position: outside;
}

.full-article-content li {
    margin-bottom: 0;
    padding-bottom: 0;
    line-height: 2.0;
}

.full-article-content ul ul,
.full-article-content ol ol,
.full-article-content ul ol,
.full-article-content ol ul {
    margin-left: 20px;
    padding-left: 14px;
}

.full-article-tags {
  color: #777;
  border-top: 2px solid #777;
  padding-top: 8px;
}

.yt-icon {
    position: absolute;
    top: 16px;
    right: 13px;
    width: 32px;
    height: auto;
    padding: 2px;
}
