/*
Theme Name: Samachara Hakku ePaper
Theme URI: https://epaper.samacharahakku.com/
Author: SS Web Solutions
Description: Professional responsive Telugu ePaper WordPress Theme
Version: 1.1.0
Requires at least: 6.0
Requires PHP: 7.4
License: GPL-2.0-or-later
Text Domain: samacharahakku-epaper
*/


/* =========================================================
   ROOT VARIABLES
========================================================= */

:root{
    --yellow:#fff000;
    --yellow-dark:#d6c900;

    --blue:#283593;
    --blue2:#3f51b5;

    --border:#d8d8d8;
    --bg:#f6f7f9;
    --text:#222;

    --ticker:#fff3e0;
    --ticker-red:#e65100;
}


/* =========================================================
   GLOBAL
========================================================= */

*{
    box-sizing:border-box;
}

html,
body{
    margin:0;
    padding:0;
}

body{
    font-family:
        Arial,
        "Noto Sans Telugu",
        "Nirmala UI",
        sans-serif;

    background:#fff;
    color:var(--text);
}

a{
    color:inherit;
}

img{
    max-width:100%;
    height:auto;
}


/* =========================================================
   MAIN SITE CONTAINER
========================================================= */

.site-shell{
    width:100%;
    max-width:1200px;
    margin:0 auto;
    padding:0 5px;
}


/* =========================================================
   EPAPER HEADER CONTAINER
========================================================= */

.epaper-header-container{
    width:100%;

    background:#fff;

    border:1px solid #ddd;
    border-bottom:none;

    border-radius:8px 8px 0 0;

    box-shadow:
        0 2px 5px rgba(0,0,0,.05);

    overflow:hidden;
}


/* =========================================================
   🟨 YELLOW HEADER
========================================================= */

.epaper-top-banner{

    display:flex;

    justify-content:space-between;

    align-items:center;

    gap:12px;

    padding:10px 20px;

    /* WHITE HEADER BACKGROUND BEHIND LOGO */
    background:#fff;

    color:#222;

    border-bottom:3px solid #e5e5e5;

    min-height:75px;
}


/* =========================================================
   BRAND / LOGO
========================================================= */

.brand-title{

    display:flex;

    align-items:center;

    gap:10px;

    text-decoration:none;

    color:#222;

    font-size:22px;

    font-weight:700;

    line-height:1;
}


.brand-logo{

    display:block;

    width:auto;

    max-width:520px;

    max-height:72px;

    height:auto;

    object-fit:contain;
}


/* =========================================================
   EPAPER BADGE
========================================================= */

.brand-subtitle{

    font-size:13px;

    background:#fff;

    color:#333;

    padding:5px 12px;

    border-radius:20px;

    white-space:nowrap;

    font-weight:700;

    border:1px solid #d6c900;
}


/* =========================================================
   BREAKING / LATEST NEWS TICKER
========================================================= */

.epaper-ticker-wrapper{

    display:flex;

    align-items:center;

    background:#fff3e0;

    border-top:1px solid #ffe0b2;

    border-bottom:1px solid #ddd;

    overflow:hidden;

    padding:8px 12px;
}


/* Ticker Badge */

.ticker-badge{

    background:#e65100;

    color:#fff;

    font-size:12px;

    font-weight:700;

    padding:5px 9px;

    border-radius:4px;

    display:flex;

    align-items:center;

    gap:5px;

    white-space:nowrap;

    margin-right:10px;

    flex-shrink:0;
}


/* Ticker Content */

.ticker-content{

    overflow:hidden;

    white-space:nowrap;

    width:100%;
}


/* Ticker Text */

.ticker-text{

    display:inline-block;

    padding-left:100%;

    animation:
        tickerAnimation 25s
        linear infinite;

    font-size:13px;

    color:#333;

    font-weight:500;
}


/* Ticker Animation */

@keyframes tickerAnimation{

    0%{
        transform:translateX(0);
    }

    100%{
        transform:translateX(-100%);
    }

}


/* =========================================================
   TOOLBAR
========================================================= */

.epaper-toolbar{

    display:flex;

    flex-direction:column;

    gap:4px;

    background:#f8f9fa;

    padding:8px 10px;

    border-left:1px solid #ccc;

    border-right:1px solid #ccc;

    border-bottom:1px solid #ccc;
}


/* Toolbar Row */

.toolbar-row{

    display:flex;

    gap:5px;

    justify-content:space-between;

    align-items:center;

    width:100%;
}


/* =========================================================
   TOOLBAR BUTTON
========================================================= */

.epaper-btn{

    background:#0073aa;

    color:#fff;

    border:none;

    padding:7px 8px;

    font-size:12px;

    font-weight:700;

    border-radius:4px;

    cursor:pointer;

    text-decoration:none;

    display:inline-flex;

    align-items:center;

    justify-content:center;

    gap:4px;

    transition:
        .2s ease;

    white-space:nowrap;

    flex:1;

    min-height:32px;
}


.epaper-btn:hover{

    filter:brightness(.9);

    color:#fff;
}


/* =========================================================
   BUTTON COLORS
========================================================= */

.btn-home{
    background:#283593;
}

.btn-about{
    background:#388e3c;
}

.btn-privacy{
    background:#d81b60;
}

.btn-contact{
    background:#e65100;
}

.btn-zoom{
    background:#0277bd;
}

.btn-reset{
    background:#455a64;
}

.btn-archive{
    background:#00838f;
}

.btn-crop{
    background:#6a1b9a;
}

.btn-share{
    background:#2e7d32;
}

.btn-pdf{
    background:#c62828;
}


/* =========================================================
   ARCHIVE
========================================================= */

.archive-wrapper{

    position:relative;

    display:flex;

    flex:1;
}


#archiveDate{

    position:absolute;

    left:0;

    top:0;

    width:100%;

    height:100%;

    opacity:0;

    cursor:pointer;

    z-index:2;
}


/* =========================================================
   EPAPER BODY
========================================================= */

.epaper-body-container{

    display:flex;

    gap:15px;

    width:100%;

    margin-top:10px;
}


/* =========================================================
   LEFT THUMBNAILS
========================================================= */

.epaper-sidebar{

    width:15%;

    max-height:850px;

    overflow-y:auto;

    display:flex;

    flex-direction:column;

    gap:12px;
}


/* Thumbnail */

.thumb-item{

    position:relative;

    border:2px solid #ddd;

    border-radius:4px;

    overflow:hidden;

    cursor:pointer;

    background:#fff;
}


/* Active Thumbnail */

.thumb-item.active{

    border-color:#0073aa;

    box-shadow:
        0 0 5px
        rgba(0,115,170,.5);
}


.thumb-item img{

    width:100%;

    display:block;
}


/* Page Number */

.thumb-item .page-num{

    position:absolute;

    bottom:4px;

    right:4px;

    background:rgba(0,0,0,.7);

    color:#fff;

    font-size:11px;

    padding:2px 6px;

    border-radius:3px;
}


/* =========================================================
   MAIN EPAPER AREA
========================================================= */

.epaper-main-container{

    width:85%;

    min-width:0;
}


/* =========================================================
   INFO BAR
========================================================= */

.epaper-info-bar{

    display:flex;

    justify-content:space-between;

    align-items:center;

    background:#e2e8f0;

    padding:8px 12px;

    font-weight:700;

    font-size:14px;

    color:#333;

    border:1px solid #ccc;

    border-bottom:none;
}


/* =========================================================
   PAGE NAVIGATION
========================================================= */

.page-nav{

    display:flex;

    align-items:center;

    gap:5px;
}


.page-nav button{

    cursor:pointer;

    border:none;

    background:#0073aa;

    color:#fff;

    padding:5px 9px;

    border-radius:4px;

    font-weight:700;
}


/* =========================================================
   MAIN PAPER VIEWER
========================================================= */

.epaper-main{

    max-height:850px;

    overflow:auto;

    border:1px solid #ccc;

    background:#f9f9f9;

    text-align:center;

    cursor:grab;

    user-select:none;

    min-height:400px;
}


.epaper-main:active{

    cursor:grabbing;
}


/* Main Image */

.epaper-main img{

    width:100%;

    max-width:none;

    height:auto;

    display:block;

    margin:0 auto;

    transition:
        width .2s ease;

    pointer-events:none;
}


/* =========================================================
   LOADING
========================================================= */

.epaper-loading{

    padding:50px;

    font-size:16px;

    color:#666;

    text-align:center;
}


/* =========================================================
   FOOTER
========================================================= */

.epaper-footer{

    width:100%;

    margin:15px auto 0;

    background:#1a237e;

    color:#fff;

    border-radius:
        0 0 8px 8px;

    padding:20px;

    font-size:14px;
}


/* Footer Content */

.footer-content{

    display:flex;

    justify-content:space-between;

    align-items:center;

    flex-wrap:wrap;

    gap:15px;

    border-bottom:
        1px solid
        rgba(255,255,255,.2);

    padding-bottom:15px;
}


/* Footer Left */

.footer-left h3{

    margin:0 0 5px;

    font-size:18px;

    color:#fff;
}


.footer-left p{

    margin:0;

    color:#cfd8dc;

    font-size:13px;
}


/* Footer Links */

.footer-links{

    display:flex;

    gap:15px;

    flex-wrap:wrap;
}


.footer-links a{

    color:#fff;

    text-decoration:none;

    font-size:13px;

    transition:.2s ease;
}


.footer-links a:hover{

    color:#ffb74d;
}


/* Footer Bottom */

.footer-bottom{

    text-align:center;

    padding-top:15px;

    font-size:12px;

    color:#c5cae9;
}


/* =========================================================
   ACCESSIBILITY
========================================================= */

.screen-reader-text{

    position:absolute!important;

    width:1px;

    height:1px;

    padding:0;

    margin:-1px;

    overflow:hidden;

    clip:rect(0,0,0,0);

    white-space:nowrap;

    border:0;
}


/* =========================================================
   TABLET
========================================================= */

@media(max-width:992px){

    .brand-logo{

        max-width:400px;

        max-height:65px;
    }

}


/* =========================================================
   📱 MOBILE
========================================================= */

@media(max-width:768px){

    html,
    body{

        width:100%;

        overflow-x:hidden;
    }


    body{

        padding-bottom:150px;
    }


    /* Main container */

    .site-shell{

        width:100%;

        max-width:100%;

        padding:0;
    }


    /* Header */

    .epaper-header-container{

        width:100%;

        border-radius:0;

        border-left:none;

        border-right:none;
    }


    /* WHITE MOBILE HEADER */

    .epaper-top-banner{

        display:flex;

        justify-content:center;

        align-items:center;

        padding:5px 10px;

        min-height:58px;

        background:#fff;

        border-radius:0;

        border-bottom:
            3px solid
            #e5e5e5;
    }


    /* Logo Mobile */

    .brand-title{

        width:100%;

        justify-content:center;

        color:#222;
    }


    .brand-logo{

        width:auto;

        max-width:90%;

        max-height:52px;

        height:auto;
    }


    /* Hide badge */

    .brand-subtitle{

        display:none;
    }


    /* =====================================================
       TICKER MOBILE
    ===================================================== */

    .epaper-ticker-wrapper{

        padding:7px 8px;

        min-height:42px;
    }


    .ticker-badge{

        font-size:11px;

        padding:5px 7px;

        margin-right:7px;
    }


    .ticker-text{

        font-size:12px;

        animation-duration:22s;
    }


    /* =====================================================
       TOOLBAR MOBILE
    ===================================================== */

    .epaper-toolbar{

        position:sticky;

        top:0;

        z-index:1000;

        background:#f8f9fa;

        box-shadow:
            0 2px 5px
            rgba(0,0,0,.12);

        padding:6px;

        gap:4px;
    }


    .toolbar-row{

        display:flex;

        flex-wrap:nowrap;

        gap:3px;

        overflow:hidden;

        width:100%;
    }


    .epaper-btn{

        font-size:10px;

        padding:5px 3px;

        min-width:0;

        min-height:32px;

        overflow:hidden;

        text-overflow:ellipsis;

        white-space:nowrap;
    }


    .epaper-btn i{

        font-size:10px;
    }


    /* =====================================================
       BODY MOBILE
    ===================================================== */

    .epaper-body-container{

        flex-direction:column;

        gap:0;

        width:100%;

        margin-top:0;
    }


    /* Hide thumbnails */

    .epaper-sidebar{

        display:none!important;
    }


    .epaper-main-container{

        width:100%;

        min-width:100%;
    }


    /* Info bar */

    .epaper-info-bar{

        font-size:12px;

        padding:7px 9px;
    }


    .page-nav{

        gap:3px;
    }


    .page-nav button{

        padding:5px 8px;

        font-size:12px;
    }


    /* Paper */

    .epaper-main{

        width:100%;

        max-height:75vh;

        min-height:300px;

        border-left:none;

        border-right:none;

        overflow:auto;
    }


    .epaper-main img{

        width:100%;

        height:auto;
    }


    /* =====================================================
       📌 FIXED MOBILE FOOTER
    ===================================================== */

    .epaper-footer{

        position:fixed;

        left:0;

        right:0;

        bottom:0;

        z-index:1100;

        width:100%;

        max-width:none;

        margin:0;

        border-radius:0;

        padding:8px 6px 7px;

        box-shadow:
            0 -3px 12px
            rgba(0,0,0,.20);
    }


    /* Footer Content */

    .footer-content{

        flex-direction:column;

        text-align:center;

        gap:5px;

        border-bottom:none;

        padding-bottom:3px;
    }


    /* Footer Message */

    .footer-left{

        width:100%;
    }


    .footer-left p{

        font-size:10px;

        margin:0;

        line-height:1.3;
    }


    /* Footer Buttons */

    .footer-links{

        width:100%;

        display:flex;

        justify-content:space-around;

        align-items:center;

        gap:2px;

        flex-wrap:nowrap;
    }


    .footer-links a{

        flex:1;

        display:flex;

        flex-direction:column;

        align-items:center;

        justify-content:center;

        gap:2px;

        padding:3px 1px;

        font-size:10px;

        line-height:1.15;

        white-space:nowrap;
    }


    .footer-links a i{

        font-size:16px;

        line-height:1;
    }


    /* Footer Copyright */

    .footer-bottom{

        padding-top:5px;

        margin-top:3px;

        font-size:9px;

        border-top:
            1px solid
            rgba(255,255,255,.2);
    }

}


/* =========================================================
   VERY SMALL MOBILE
========================================================= */

@media(max-width:380px){

    .epaper-top-banner{

        min-height:52px;

        padding:4px 6px;
    }


    .brand-logo{

        max-width:94%;

        max-height:46px;
    }


    .ticker-badge{

        font-size:10px;

        padding:4px 5px;
    }


    .ticker-text{

        font-size:11px;
    }


    .epaper-toolbar{

        padding:4px;
    }


    .epaper-btn{

        font-size:9px;

        padding:4px 2px;

        min-height:29px;
    }


    .epaper-btn i{

        font-size:9px;
    }


    body{

        padding-bottom:145px;
    }


    .epaper-footer{

        padding:6px 4px;
    }


    .footer-links a{

        font-size:9px;
    }


    .footer-links a i{

        font-size:14px;
    }

}