@charset "UTF-8";

/* Ranking List Container */
.ssrd-ranking-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* List Item */
.ssrd-ranking-item {
    margin: 0;
    padding: 0;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Link Wrapper */
.ssrd-link {
    display: flex;
    text-decoration: none;
    color: inherit;
    align-items: flex-start;
    gap: 12px;
}

.ssrd-link:hover {
    text-decoration: none;
    opacity: 0.9;
}

/* Card Style Modification */
.ssrd-card-style .ssrd-ranking-item {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

.ssrd-card-style .ssrd-link {
    padding: 12px;
}

.ssrd-card-style .ssrd-ranking-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

/* Thumbnail Area */
.ssrd-thumb {
    position: relative;
    flex-shrink: 0;
    width: 100px;
    aspect-ratio: 16 / 9;
    border-radius: 4px;
    overflow: hidden;
    background-color: #f0f0f0;
}

.ssrd-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ssrd-no-thumb {
    display: block;
    width: 100%;
    height: 100%;
    background-color: #ddd;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23999' stroke-width='1' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='18' height='18' rx='2' ry='2'%3E%3C/rect%3E%3Ccircle cx='8.5' cy='8.5' r='1.5'%3E%3C/circle%3E%3Cpolyline points='21 15 16 10 5 21'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
}

/* Rank Badge */
.ssrd-rank-badge {
    position: absolute;
    top: 0;
    left: 0;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    font-size: 10px;
    font-weight: bold;
    padding: 2px 6px;
    border-bottom-right-radius: 4px;
    line-height: 1;
}

/* Rank Only (No Thumb) */
.ssrd-rank-only {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    background: #555;
    color: #fff;
    text-align: center;
    line-height: 24px;
    border-radius: 50%;
    font-size: 11px;
    font-weight: bold;
    margin-right: 4px;
}

/* Rank 1-3 Styling */
.ssrd-ranking-item:nth-child(1) .ssrd-rank-badge,
.ssrd-ranking-item:nth-child(1) .ssrd-rank-only {
    background: #d4af37;
    /* Gold */
}

.ssrd-ranking-item:nth-child(2) .ssrd-rank-badge,
.ssrd-ranking-item:nth-child(2) .ssrd-rank-only {
    background: #c0c0c0;
    /* Silver */
}

.ssrd-ranking-item:nth-child(3) .ssrd-rank-badge,
.ssrd-ranking-item:nth-child(3) .ssrd-rank-only {
    background: #cd7f32;
    /* Bronze */
}

/* Content Area */
.ssrd-content {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

/* Title */
.ssrd-title {
    font-size: 14px;
    /* Normal font size as requested */
    font-weight: 500;
    line-height: 1.4;
    margin-bottom: 4px;
    color: #333;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Meta Info (Views) */
.ssrd-meta {
    font-size: 11px;
    color: #888;
    display: flex;
    align-items: center;
    gap: 4px;
}

.ssrd-pv::before {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23888' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z'%3E%3C/path%3E%3Ccircle cx='12' cy='12' r='3'%3E%3C/circle%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    vertical-align: middle;
    margin-right: 2px;
    position: relative;
    top: -1px;
}

/**
 * 角丸なし（Square Style）
 * 詳細度を高めて確実に適用させる
 */
ul.ssrd-ranking-list.ssrd-square-style .ssrd-ranking-item,
ul.ssrd-ranking-list.ssrd-square-style .ssrd-thumb,
ul.ssrd-ranking-list.ssrd-square-style .ssrd-thumb img,
ul.ssrd-ranking-list.ssrd-square-style .ssrd-rank-badge,
ul.ssrd-ranking-list.ssrd-square-style .ssrd-rank-only {
    border-radius: 0 !important;
}

@media (max-width: 480px) {
    .ssrd-card-style .ssrd-ranking-item {
        width: 100%;
        /* スマホでは1列 */
    }
}