/* ==========================================================================
   7. SECTION B: 1:1 HORIZONTAL CATEGORY CAROUSEL SYSTEM
   ========================================================================== */
.topics-feed-system {
    display: flex;
    flex-direction: column;
    gap: 3.5rem;
}

.topic-row {
    display: grid;
    grid-template-columns: 200px 1fr;
    align-items: start;
    gap: 2rem;
}

.topic-sidebar {
    position: sticky;
    top: 90px;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.topic-sidebar-title {
    font-size: 1.6rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.btn-see-posts {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: var(--google-link-blue);
    border: 1px solid var(--border-color);
    font-size: 0.8rem;
    font-weight: 500;
    padding: 0.45rem 0.9rem;
    border-radius: 4px;
    transition: background-color 0.15s;
}

.btn-see-posts:hover {
    background-color: rgba(138, 180, 248, 0.08);
}

.topic-carousel-container {
    position: relative;
    width: 100%;
    margin: 0;
}

.topic-grid-clip {
    overflow: hidden;
    width: 100%;
}

.topic-grid {
    display: flex;
    flex-wrap: nowrap;
    gap: 20px;
    width: 100%;
    transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1);
}

.topic-card {
    flex: 0 0 calc((100% - 40px) / 3);
    box-sizing: border-box;
}

.topic-card-title a {
    text-decoration: none;
    color: var(--text-primary);
    font-size: 0.95rem;
    font-weight: 400;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 2.7rem;
    margin-bottom: 0.5rem;
}

.topic-card-title a:hover {
    color: var(--google-link-blue);
}

.topic-card-image {
    width: 100%;
    height: 160px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    background-color: var(--surface-card);
}

.topic-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.topic-row-prev,
.topic-row-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(32, 33, 36, 0.9);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.25rem;
    box-shadow: 0 4px 8px rgba(0,0,0,0.5);
    z-index: 10;
    transition: background-color 0.2s;
}

.topic-row-prev:hover,
.topic-row-next:hover {
    background-color: #303134;
}

.topic-row-prev {
    left: -18px;
}

.topic-row-next {
    right: -18px;
}

.topic-row-dots {
    display: flex;
    justify-content: center;
    gap: 0.4rem;
    margin-top: 1.5rem;
}

.topic-row-dots .sub-dot {
    width: 7px;
    height: 7px;
    background-color: #5f6368;
    border-radius: 50%;
    transition: background-color 0.2s;
}

.topic-row-dots .sub-dot.active {
    background-color: #ffffff;
}
