/* ================================
   AUTHOR AREA HARD SCOPE
   ================================ */

body {
    background: #f9fafb;
}

/* Shield author UI from global styles */
.journal-admin-layout *,
.author-topbar *,
.author-sidebar *,
.journal-admin-content * {
    box-sizing: border-box;
}


/* ================================
   SANMINIT AUTHOR DASHBOARD LAYOUT
   ================================ */

/* ---- Browser normalization ---- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

/* ---- Variables ---- */
:root {
    --author-header-height: 64px;
    --sanminit-green: #0A8A33;
    --sanminit-green-dark: #0c6d29;
    --bg-light: #f9fafb;
}

/* ---- Author Header ---- */
.author-topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;

    height: var(--author-header-height);
    background: var(--sanminit-green);
    background-color: #0A8A33;
    color: #ffffff;

    display: flex;
    justify-content: space-between;
    align-items: center;

    padding: 0 28px;
    z-index: 1000;
}

/* Left side */
.author-topbar-left {
    display: flex;
    align-items: center;
    gap: 18px;
}

.author-logo-img {
    height: 42px;
    width: auto;
}

/* Nav */
.author-journal-nav a {
    color: #ffffff;
    text-decoration: none;
    font-size: 0.9rem;
    margin-right: 18px;
}

.author-journal-nav a:hover {
    text-decoration: underline;
}

/* Right side */
.author-topbar-right {
    display: flex;
    align-items: center;
    gap: 14px;
    text-align: right;
}

.author-user-name {
    font-weight: 600;
    font-size: 0.9rem;
}

.author-user-meta {
    font-size: 0.75rem;
    opacity: 0.9;
}

.author-user-email {
    font-size: 0.75rem;
    opacity: 0.8;
}

.author-logout {
    background: rgba(255,255,255,0.18);
    color: #ffffff;
    padding: 6px 14px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.85rem;
}

.author-logout:hover {
    background: rgba(255,255,255,0.28);
}

/* ---- Main Layout ---- */
.journal-admin-layout {
    min-height: calc(100vh - var(--author-header-height)); 
    display: flex;
    margin-top: var(--author-header-height);
    background: var(--bg-light);
    align-items: stretch;
}

/* ---- Sidebar ---- */
.author-sidebar {
    width: 15%;
    min-width: 200px;
    max-width: 280px;
    background: var(--sanminit-green);
    color: #ffffff;
    padding: 22px 18px;
    flex-shrink: 0;
}

.author-nav {
    list-style: none;
    padding: 0;
    margin: 0;
}

.author-nav li {
    margin-bottom: 10px;
}

.author-nav a {
    display: block;
    padding: 10px 12px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    color: #ffffff;
}

.author-nav a:hover,
.author-nav a.active {
    background: rgba(255,255,255,0.18);
}

/* ---- Main Content ---- */
.journal-admin-content {
    flex: 1;
    padding: 28px;
    background: var(--bg-light);
}

/* ---- Content Box ---- */
.admin-content-box {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 22px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

/* ---- Tables ---- */
.admin-content-box table {
    width: 100%;
    border-collapse: collapse;
}

.admin-content-box th,
.admin-content-box td {
    vertical-align: top;
}

.journal-admin-layout .status-draft { background:#fef3c7; color:#92400e; }
.journal-admin-layout .status-submitted { background:#e0f2fe; color:#075985; }
.journal-admin-layout .status-under_review { background:#ffedd5; color:#9a3412; }
.journal-admin-layout .status-published { background:#bbf7d0; color:#065f46; }


/* 🔒 FORCE author header color across browsers */
.author-topbar {
    background-color: #0A8A33 !important;
}


/*-- added Jan 4, 2026 to force sidebar to the side on mobile devices--*/
/* ================================
   MOBILE PORTRAIT FIXES (iPhone)
   ================================ */

@media (max-width: 768px) {

    /* Reserve space for fixed header */
    body {
        padding-top: var(--author-header-height);
        overflow-x: hidden;
    }

    /* Stack layout vertically */
    .journal-admin-layout {
        flex-direction: column;
        margin-top: 0;
        min-height: auto;
    }

    /* Sidebar sits fully below header */
    .author-sidebar {
        width: 100%;
        min-width: 0;
        max-width: none;
        padding: 14px 16px;
        position: relative;
        top: 0;
    }

    /* Author Navigation */
   
    .author-nav {
        display: flex;
        flex-wrap: wrap;
        gap: 10px;
    }

    .author-nav li {
        margin: 0;
    }

    .author-nav a {
        padding: 8px 10px;
        font-size: 0.85rem;
        white-space: nowrap;
    }

    /* Content uses full width */
    .journal-admin-content {
        padding: 16px;
        width: 100%;
    }


    /* Footer must respect viewport */
    footer {
        width: 100vw;
        margin-left: calc(-50vw + 50%);
    }

}
/*--ends the addithin sidebar Jan 4, 2026--*/
