/*
Theme Name: Papr Child
Template: papr
*/

/* ==========================
GAME NAVIGATION
========================== */

.game-nav{
    margin-top:20px;
    margin-bottom:10px;
    font-size:15px;
    line-height:1.8;
}

.game-nav a{
    display:inline-block;
    padding:6px 12px;
    background:#f5f5f5;
    margin:3px 5px 3px 0;
    border-radius:4px;
    text-decoration:none;
    color:#333;
    font-weight:500;
    transition:background .2s ease, color .2s ease;
}

.game-nav a:hover,
.game-nav a[aria-current="page"]{
    background:#e9e9e9;
    color:#000;
}

.game-nav-separator{
    margin-right:6px;
    color:#999;
}

/* ==========================
GAME SECTIONS
========================== */

.game-section{
    margin-top:50px;
    margin-bottom:50px;
    clear:both;
}

.game-section-title{
    font-size:24px;
    font-weight:700;
    margin-bottom:20px;
}

/* ==========================
GAME INFO (SEO BLOCK)
========================== */

.game-info-box{
    background:#f9f9f9;
    border:1px solid #e7e7e7;
    padding:28px;
    border-radius:10px;
    margin:35px 0 40px;
    box-shadow:0 2px 10px rgba(0,0,0,.04);
}

.post-details .game-info-box .game-section-title{
    color:#111 !important;
    font-size:26px;
    font-weight:700;
    line-height:1.3;
    margin:0 0 22px;
    padding-bottom:12px;
    border-bottom:2px solid #e9e9e9;
}

.post-details .game-info-box .game-section-title::before{
    content:"🎮";
    margin-right:10px;
}

.game-info-list{
    list-style:none;
    margin:0;
    padding:0;
    display:grid;
    grid-template-columns:repeat(2, minmax(0, 1fr));
    gap:12px 20px;
}

.game-info-list li{
    margin:0;
    padding:14px 16px;
    border:1px solid #ececec;
    border-radius:8px;
    background:#fff;
    font-size:15px;
    line-height:1.5;
}

.game-info-list strong{
    display:block;
    margin:0 0 4px;
    color:#222;
    font-weight:700;
    font-size:13px;
    text-transform:uppercase;
    letter-spacing:.03em;
}

.game-info-list span,
.game-info-list li{
    color:#444;
}

@media (max-width:768px){
    .game-info-box{
        padding:22px;
    }

    .game-info-list{
        grid-template-columns:1fr;
        gap:10px;
    }

    .post-details .game-info-box .game-section-title{
        font-size:22px;
    }
}

/* ==========================
GAME HEADER / BOX ART + INFO
========================== */

.game-header-card{
    display:grid;
    grid-template-columns:280px 1fr;
    gap:24px;
    align-items:start;
    margin:35px 0 40px;
}

.game-boxart{
    display:block;
}

.game-boxart img{
    width:100%;
    display:block;
    border-radius:10px;
    border:1px solid #e7e7e7;
    box-shadow:0 2px 10px rgba(0,0,0,.06);
    background:#fff;
}

.game-header-info{
    min-width:0;
}

.game-info-columns{
    display:grid;
    grid-template-columns:repeat(2, minmax(0, 1fr));
    gap:20px;
}

.game-info-group h3{
    margin:0 0 14px;
    font-size:18px;
    line-height:1.3;
    color:#111;   
    font-weight:600;
}

.game-info-box .game-info-group h3{
    color:#111 !important;
}

.hash-value{
    font-family:monospace;
    font-size:13px;
    word-break:break-all;
}

@media (max-width:992px){
    .game-header-card{
        grid-template-columns:220px 1fr;
    }
}

@media (max-width:768px){
    .game-header-card{
        grid-template-columns:1fr;
    }

    .game-boxart{
        max-width:320px;
    }

    .game-info-columns{
        grid-template-columns:1fr;
    }
}

/* ==========================
MEDIA GALLERY
========================== */

.post-details .game-section.media{
    display:block;
    clear:both !important;
    overflow:hidden;
    margin-top:50px;
    margin-bottom:50px;
    position:relative;
}

.post-details .game-section.media .game-section-title{
    display:block;
    clear:both !important;
    position:relative;
    z-index:5;
    margin:0 0 24px 0 !important;
    padding:0;
    line-height:1.3;
}

.post-details .game-section.media .media-gallery-wrapper{
    display:block;
    clear:both !important;
    position:relative;
    z-index:1;
    margin:0 !important;
    padding:0 !important;
}

.post-details .game-section.media .media-gallery{
    display:grid !important;
    grid-template-columns:repeat(auto-fit, minmax(220px, 1fr));
    gap:14px;
    clear:both !important;
    margin:0 !important;
    padding:0 !important;
    align-items:start;
}

.post-details .game-section.media .media-item{
    display:block;
    position:relative;
    overflow:hidden;
    border-radius:6px;
    margin:0 !important;
    padding:0 !important;
    float:none !important;
    width:100% !important;
    max-width:100% !important;
}

.post-details .game-section.media .media-item a{
    display:block;
    margin:0 !important;
    padding:0 !important;
    line-height:0;
}

.post-details .game-section.media .media-item img{
    display:block !important;
    width:100% !important;
    height:auto !important;
    max-width:100% !important;
    margin:0 !important;
    float:none !important;
    position:relative;
    z-index:1;
    border-radius:6px;
    transition:transform .2s ease;
}

.post-details .game-section.media .media-item:hover img{
    transform:scale(1.03);
}

/* fixes for theme image styles */
.post-details .game-section.media img,
.post-details .game-section.media a img,
.post-details .game-section.media figure,
.post-details .game-section.media .wp-caption{
    float:none !important;
    clear:none !important;
    margin-top:0 !important;
    margin-bottom:0 !important;
}

.post-details .game-section.media::before,
.post-details .game-section.media::after,
.post-details .game-section.media .media-gallery-wrapper::before,
.post-details .game-section.media .media-gallery-wrapper::after{
    content:"";
    display:table;
}

.post-details .game-section.media::after,
.post-details .game-section.media .media-gallery-wrapper::after{
    clear:both;
}

/* ==========================
VIDEO BLOCK
========================== */

.game-video-block{
    margin-top:40px;
    margin-bottom:50px;
}

.video-wrapper{
    position:relative;
    padding-bottom:56.25%;
    height:0;
    overflow:hidden;
    border-radius:6px;
}

.video-wrapper iframe,
.video-wrapper embed,
.video-wrapper object{
    position:absolute;
    top:0;
    left:0;
    width:100%;
    height:100%;
}

/* ==========================
ROM DOWNLOAD
========================== */

.rom-download-page{
    margin:40px 0 50px;
    padding:30px;
    background:#f9f9f9;
    border:1px solid #e7e7e7;
    border-radius:10px;
    box-shadow:0 2px 10px rgba(0,0,0,.04);
}

.rom-download-page h2{
    color:#111;
    font-size:26px;
    font-weight:700;
    line-height:1.3;
    margin:0 0 22px;
    padding-bottom:12px;
    border-bottom:2px solid #e9e9e9;
}

.rom-download-page h2::before{
    content:"💾";
    margin-right:10px;
}

.rom-download-meta{
    display:grid;
    grid-template-columns:repeat(3, minmax(0, 1fr));
    gap:12px 16px;
    margin-bottom:22px;
}

.rom-download-meta p{
    margin:0;
    padding:14px 16px;
    background:#fff;
    border:1px solid #ececec;
    border-radius:8px;
    font-size:15px;
    line-height:1.5;
    color:#444;
}

.rom-download-meta strong{
    display:block;
    margin:0 0 4px;
    color:#222;
    font-weight:700;
    font-size:13px;
    text-transform:uppercase;
    letter-spacing:.03em;
}

.download-rom-btn{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    gap:8px;
    margin-top:4px;
    padding:14px 30px;
    background:#ff3d00;
    color:#fff;
    font-weight:700;
    font-size:15px;
    line-height:1;
    border-radius:8px;
    text-decoration:none;
    transition:transform .15s ease, background .2s ease, box-shadow .2s ease;
    box-shadow:0 6px 18px rgba(255,61,0,.25);
}

.download-rom-btn:hover{
    background:#e63600;
    color:#fff;
    transform:translateY(-1px);
}

.download-rom-btn::before{
    content:"⬇";
    font-size:14px;
}

.rom-download-count{
    margin-top:14px;
    font-size:14px;
    color:#666;
}

@media (max-width:768px){
    .rom-download-page{
        padding:22px;
    }

    .rom-download-page h2{
        font-size:22px;
    }

    .rom-download-meta{
        grid-template-columns:1fr;
        gap:10px;
    }

    .download-rom-btn{
        width:100%;
        padding:15px 20px;
    }
}

/* ==========================
RESPONSIVE
========================== */

@media (max-width:600px){
    .game-nav{
        font-size:14px;
    }

    .game-nav-separator{
        display:none;
    }

    .game-nav a{
        margin-right:6px;
    }
}

html{
    scroll-behavior:smooth;
}

/* ==========================
GAME INFO TITLE FIX
========================== */

.game-info-box .game-section-title{
    color:#111;
    font-weight:700;
    border-bottom:2px solid #eee;
    padding-bottom:10px;
    margin-bottom:20px;
}
.game-info-box .game-section-title::before{
    content:"🎮";
    margin-right:8px;
}

.post-details .rom-download-page h2{
    color:#111 !important;
    font-size:26px;
    font-weight:700;
    line-height:1.3;
    margin:0 0 22px;
    padding-bottom:12px;
    border-bottom:2px solid #e9e9e9;
}
.post-details .rom-download-page h2::before{
    content:"💾";
    margin-right:10px;
}

/* ==========================
SIMILAR GAMES
========================== */

.cv-similar-games{
    margin:50px 0;
}

.cv-similar-games-grid{
    display:grid;
    grid-template-columns:repeat(4, minmax(0, 1fr));
    gap:20px;
}

.cv-similar-game-card{
    display:flex;
    flex-direction:column;
    background:#fff;
    border:1px solid #e7e7e7;
    border-radius:10px;
    overflow:hidden;
    box-shadow:0 2px 10px rgba(0,0,0,.04);
}

.cv-similar-game-thumb{
    display:block;
    background:#f8f8f8;
}

.cv-similar-game-thumb img{
    width:100%;
    display:block;
    aspect-ratio:3 / 4;
    object-fit:cover;
}

.cv-similar-game-content{
    padding:14px;
}

.cv-similar-game-title{
    margin:0 0 10px;
    font-size:16px;
    line-height:1.35;
}

.cv-similar-game-title a{
    color:#111;
    text-decoration:none;
}

.cv-similar-game-title a:hover{
    text-decoration:underline;
}

.cv-similar-game-meta{
    display:flex;
    flex-direction:column;
    gap:6px;
    font-size:13px;
    color:#666;
}

@media (max-width:992px){
    .cv-similar-games-grid{
        grid-template-columns:repeat(2, minmax(0, 1fr));
    }
}

@media (max-width:576px){
    .cv-similar-games-grid{
        grid-template-columns:1fr;
    }
}

/* ==========================
GAME INFO BADGES
========================== */

.info-badges{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
}

.info-badge{
    display:inline-flex;
    align-items:center;
    padding:6px 10px;
    background:#f3f3f3;
    border:1px solid #e5e5e5;
    border-radius:999px;
    font-size:13px;
    line-height:1.2;
    color:#222;
    white-space:nowrap;
}

/* fix long values inside Game Info */
.game-info-columns{
    align-items:start;
}

.game-info-list li{
    min-width:0;
}

.game-info-list .info-badges{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
    max-width:100%;
}

.game-info-list .info-badge{
    white-space:normal;
    word-break:keep-all;
    overflow-wrap:break-word;
}

