:root {
    --gap: 15px;
    --main-blue: #3da2d5;
}

body {
    background-color: #e2e5e9;
    margin: 0;
    padding: 0;
    color: #333;
    font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
}

.cvx-main {
    max-width: 1120px;
    margin: 0 auto;
    padding: 20px;
}

.cvx-section {
    margin-bottom: 50px;
    padding: 25px;
    border-radius: 20px;
    box-shadow: 0 12px 30px rgba(0,0,0,0.12);
    border: 1px solid rgba(0,0,0,0.08);
    position: relative;
    background-color: #fff;
}

/* PRラベル */
.cvx-pr-label {
    position: absolute;
    top: 20px;
    right: 25px;
    font-size: 10px;
    color: #888;
    border: 1px solid #ccc;
    padding: 1px 6px;
    border-radius: 3px;
    background: rgba(255,255,255,0.8);
    z-index: 10;
}

/* セクション配色 */
.sec-rank_tot { background-color: #fffaf0; border-color: #ffcc99; } 
.sec-rank_ln  { background-color: #f0f5ff; border-color: #bbd3ff; } 
.sec-today    { background-color: #fff5f5; border-color: #ffcccc; } 
.sec-future   { background-color: #f5fff8; border-color: #c2f0d1; } 
.sec-past     { background-color: #fcf5ff; border-color: #e4ccff; } 

.cvx-section h2 {
    font-size: 1.4rem;
    border-left: 8px solid #333;
    padding-left: 15px;
    margin-bottom: 40px;
    color: #111;
    font-weight: 800;
}

/* TOP3 エリア（王冠・段差） */
.cvx-top3-area {
    position: relative;
    max-width: 950px;
    margin: 0 auto 30px auto;
    display: flex;
    justify-content: space-between;
    align-items: end;
    min-height: 480px;
    z-index: 20;
}

.cvx-top-1 { position: absolute; left: 50%; bottom: 0; transform: translateX(-50%); width: 32%; z-index: 100; }
.cvx-top-1 .cvx-frame { border: 2px solid #ffcc00; box-shadow: 0 20px 50px rgba(255,185,0,0.25); }
.cvx-top-2, .cvx-top-3 { width: 26%; z-index: 50; }

/* 王冠バッジ */
.cvx-badge {
    position: absolute;
    top: -30px;
    left: -20px;
    width: 60px;
    height: 60px;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 28px;
    border: 3px solid #fff;
    box-shadow: 0 8px 20px rgba(0,0,0,0.4);
    z-index: 300;
    text-shadow: 2px 2px 3px rgba(0,0,0,0.5);
}

.cvx-badge::before {
    content: "";
    position: absolute;
    top: -16px;
    left: 50%;
    transform: translateX(-50%);
    width: 44px;
    height: 22px;
    background: inherit;
    clip-path: polygon(0% 100%, 0% 0%, 25% 50%, 50% 0%, 75% 50%, 100% 0%, 100% 100%);
}

.badge-1 { background: radial-gradient(circle at 30% 30%, #ffec8b, #ffb900, #cc8400); }
.badge-2 { background: radial-gradient(circle at 30% 30%, #ffffff, #b0b0b0, #606060); }
.badge-3 { background: radial-gradient(circle at 30% 30%, #ffccaa, #d2691e, #703000); }

/* カード共通 */
.cvx-frame {
    padding: 8px;
    border-radius: 12px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
    background: #fff;
    width: 100%;
    box-sizing: border-box;
    position: relative;
}

.cvx-top img { width: 100%; aspect-ratio: 2/3; object-fit: cover; border-radius: 6px; background: #eee; }

.cvx-cap {
    font-size: 13px;
    font-weight: bold;
    margin-top: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
    height: 2.8em;
}

/* 4位以降のグリッド */
.cvx-grid {
    display: grid;
    gap: var(--gap);
    grid-template-columns: repeat(7, 1fr);
    margin-top: 10px;
}

.cvx-card {
    background: #fff;
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.1);
    position: relative;
    border: 1px solid #c0c8d0;
}

.cvx-card img {
    width: 100%;
    aspect-ratio: 2/3;
    object-fit: cover;
    border-radius: 6px;
    background: #f0f0f0;
}

.cvx-title {
    font-size: 11px;
    font-weight: 600;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-top: 10px;
    color: #111;
    text-decoration: none;
    line-height: 1.4;
    height: 2.8em;
}

.cvx-num-tag {
    position: absolute;
    top: 6px;
    left: 6px;
    background: rgba(0,0,0,0.8);
    color: #fff;
    padding: 2px 8px;
    font-size: 10px;
    border-radius: 4px;
    z-index: 10;
    font-weight: bold;
}

/* 日付バー・タブ */
.cvx-datebar {
    margin-bottom: 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.cvx-chip {
    border: 1px solid #999;
    background: #fff;
    padding: 7px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 700;
    text-align: center;
    transition: 0.2s;
}

.cvx-chip:hover { background: #f0f0f0; }
.cvx-chip.is-active { background: #111; color: #fff; border-color: #111; }

/* 専門ページボタン */
.cvx-more-btn {
    display: block;
    margin: 35px auto 0;
    padding: 14px 60px;
    background: #fff;
    color: #111;
    border: 2px solid #333;
    border-radius: 10px;
    cursor: pointer;
    font-weight: bold;
    text-align: center;
    text-decoration: none;
    transition: 0.3s;
}

.cvx-more-btn:hover { background: #333; color: #fff; }

/* フッター */
.site-footer {
    background: #333;
    color: #fff;
    padding: 50px 0;
    text-align: center;
    margin-top: 60px;
}

.footer-inner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

.cvx-footer-notice {
    font-size: 10px;
    opacity: 0.8;
    margin-bottom: 25px;
    line-height: 1.8;
}

.footer-nav {
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.footer-nav a {
    color: #fff;
    text-decoration: none;
    font-size: 13px;
    font-weight: bold;
}

.footer-nav a:hover { text-decoration: underline; }
.copyright { font-size: 11px; opacity: 0.6; margin-top: 10px; }

/* --- スマホ専用調整 --- */
@media(max-width:768px) { 
    .cvx-main { padding: 10px; }
    .cvx-section { padding: 15px; border-radius: 15px; margin-bottom: 30px; }
    
    .cvx-top3-area { min-height: 320px; margin-bottom: 20px; }
    .cvx-badge { width: 44px; height: 44px; font-size: 20px; top: -20px; left: -10px; }
    .cvx-badge::before { width: 32px; height: 16px; top: -12px; }

    .cvx-grid { 
        grid-template-columns: repeat(3, 1fr); 
        gap: 8px; 
    } 
    
    .cvx-card { padding: 8px; border-radius: 8px; }
    .cvx-title { font-size: 10px; height: 2.6em; line-height: 1.3; }

    .cvx-datebar { gap: 5px; }
    .cvx-chip { min-width: 60px; padding: 6px 4px; font-size: 10px; }

    /* 「〜専門ページへ」ボタンのスマホ改行対策 */
    .cvx-more-btn {
        width: 100%;
        padding: 12px 0;
        font-size: 14px;
        white-space: nowrap; /* 1行に強制 */
        margin-top: 25px;
    }
}