@charset "utf-8";

:root {
    --ink: #0b1f3a;
    --navy: #071b35;
    --blue: #1565c0;
    --gold: #dca73a;
    --muted: #718096;
    --paper: #f6f8fb;
    --line: #e5eaf1;
    --radius: 18px;
    --shadow: 0 18px 55px rgba(17, 43, 74, .12)
}

* {
    box-sizing: border-box
}

body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font-family: 'Noto Naskh Arabic', 'Plus Jakarta Sans', Arial, sans-serif
}

a {
    text-decoration: none;
    color: inherit
}

.shell {
    width: min(1180px, calc(100% - 40px));
    margin: auto
}

.topbar {
    background: #000000;
    color: #b7c6d9;
    font: 500 12px 'Plus Jakarta Sans'
}

.topbar-inner {
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    direction: ltr
}

.brandbar {
    padding: 18px 0;
    display: flex;
    align-items: center;
    justify-content: space-between
}

.brand {
    display: flex;
    align-items: center;
    gap: 13px;
    font: 800 20px 'Plus Jakarta Sans'
}

.brand img {
    width: 190px;
    height: 48px;
    object-fit: contain;
    object-position: right;
    border-radius: 8px
}

.brand span {
    padding-left: 13px;
    border-left: 1px solid var(--line);
    color: var(--blue)
}

.admin-link {
    font: 700 13px 'Plus Jakarta Sans';
    padding: 10px 15px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff
}

.site-nav {
    background:#000000;
}

.nav-inner {
    display: flex;
    gap: 4px;
    overflow: auto
}

.nav-inner a {
    color: #d7e1ed;
    padding: 14px 18px;
    white-space: nowrap;
    font-size: 17px;
    font-weight: 600;
    border-bottom: 3px solid transparent
}

.nav-inner a:hover,
.nav-inner a.active {
    background: #f6a13a;
    color: #fff;
    border-color: #bc2e61;
}

.hero {
    padding: 54px 0 30px;
    background: linear-gradient(45deg, #bf375b, #f69e3c);
    color: #fff
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.2fr .8fr;
    align-items: center;
    gap: 45px
}

.eyebrow {
    color: #000;
    font: 700 11px 'Plus Jakarta Sans';
    letter-spacing: 1.4px
}

.hero h1 {
    margin: 10px 0;
    font-size: clamp(31px, 4vw, 52px);
    line-height: 1.25
}

.hero p {
    color: #cfdae8;
    font-size: 19px;
    line-height: 1.8
}

.hero-card {
    padding: 25px;
    border: 1px solid #ffffff2a;
    border-radius: var(--radius);
    background: #ffffff16
}

.hero-card span,
.hero-card small {
    color: #d6e5f3
}

.hero-card strong {
    display: block;
    margin: 9px 0;
    font: 800 31px 'Plus Jakarta Sans'
}

.content,
.reader {
    padding: 40px 0 64px
}

.section-heading {
    margin-bottom: 23px
}

.section-heading h2 {
    font-size: 31px;
    margin: 0
}

.section-heading p {
    margin: 0;
    color: var(--muted);
    font-size: 17px
}

.edition-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
    gap: 22px
}

.edition-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 12px;
    transition: .25s
}

.edition-card:hover {
    transform: translateY(-7px);
    box-shadow: var(--shadow)
}

.edition-cover {
    aspect-ratio: .74;
    overflow: hidden;
    border-radius: 12px;
    background: #eef2f7
}

.edition-cover img {
    width: 100%;
    height: 100%;
   /* object-fit: cover*/
}

.edition-meta {
    padding: 14px 5px 5px;
    display: flex;
    justify-content: space-between
}

.edition-meta h3 {
    margin: 0;
    font-size: 22px
}

.edition-meta span {
    font: 700 12px 'Plus Jakarta Sans';
    color: var(--blue);
    direction: ltr
}

.empty {
    padding: 55px;
    text-align: center;
    border: 1px dashed #cbd5e1;
    background: #fff;
    border-radius: var(--radius);
    color: var(--muted);
    font-size: 19px
}

.reader-header {
    background: linear-gradient(45deg, #bf375b, #f69e3c);
    color: #fff;
    padding: 5px 0
}

.reader-header .shell {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px
}

.reader-header h1 {
    font-size: 31px;
    margin: 7px 0
}

.reader-actions {
    display: flex;
    gap: 9px;
    direction: ltr
}

.btn {
    border: 0;
    border-radius: 10px;
    padding: 11px 15px;
    cursor: pointer;
    font: 700 13px 'Plus Jakarta Sans'
}

.btn-light {
    background: #fff;
    color: var(--ink)
}

.btn-gold {
    background: #f6a13a;
    color: #172235
}

.reader-toolbar {
    padding: 18px 0;
    border-bottom: 1px solid var(--line);
    background: #fff
}

.reader-toolbar .shell {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: center
}

.date-form {
    display: flex;
    gap: 8px
}

.date-form input,
.field input,
.field select {
    border: 1px solid var(--line);
    padding: 11px 12px;
    border-radius: 9px;
    background: #fff;
    font: 500 14px 'Plus Jakarta Sans';
    width: 100%
}

.pages {
    display: flex;
    gap: 7px;
    overflow: auto
}

.pages a {
    min-width: 35px;
    height: 35px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 9px;
    font: 700 13px 'Plus Jakarta Sans';
    background: #fff
}

.pages a.active {
    background: var(--blue);
    color: #fff
}

.paper-frame {
    margin: auto;
    width: min(1050px, 100%);
    padding: 11px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 10px;
    box-shadow: var(--shadow)
}

.paper-frame img {
    display: block;
    width: 100%
}

.thumb-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(105px, 1fr));
    gap: 12px;
    margin-top: 30px
}

.thumb {
    position: relative;
    background: #fff;
    border: 2px solid transparent;
    border-radius: 11px;
    padding: 5px
}

.thumb.active {
    border-color: var(--blue)
}

.thumb img {
    display: block;
    width: 100%;
    border-radius: 6px;
}

.thumb span {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    width: 25px;
    height: 25px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: #071b35;
    color: #fff;
    font: 700 11px 'Plus Jakarta Sans'
}

.site-footer {
    background: #000000;
    color: #c6d4e4;
    padding: 31px 0
}

.footer-inner {
    display: flex;
    gap: 24px;
    justify-content: space-between;
    flex-wrap: wrap
}

.footer-inner strong {
    font: 800 18px 'Plus Jakarta Sans';
    color: #fff
}

.footer-inner strong span {
    color: #e2b64e
}

.login-wrap {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 25px;
    background: radial-gradient(circle at top right, #1f5c9d, #071b35 48%, #041225)
}

.login-card {
    width: min(440px, 100%);
    background: #fff;
    border-radius: 20px;
    padding: 36px;
    box-shadow: 0 24px 80px #0004
}

.login-card .brand {
    justify-content: center;
    margin-bottom: 30px
}

.login-card h1,
.login-card p {
    text-align: center
}

.login-card p {
    color: var(--muted)
}

.field {
    margin-bottom: 17px
}

.field label {
    display: block;
    margin-bottom: 7px;
    font-size: 16px;
    font-weight: 700
}

.submit {
    width: 100%;
    padding: 14px;
    background: var(--blue);
    color: #fff;
    border: 0;
    border-radius: 10px;
    cursor: pointer;
    font: 700 14px 'Plus Jakarta Sans'
}

.alert {
    padding: 11px 14px;
    border-radius: 9px;
    background: #fff1f1;
    color: #b42318;
    margin-bottom: 18px
}

.admin-page {
    background: #f3f6fa;
    font-family: 'Plus Jakarta Sans', 'Noto Naskh Arabic';
    direction: ltr
}

.admin-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 248px 1fr
}

.admin-sidebar {
    background: #071b35;
    padding: 25px 15px;
    color: #b9c8d9
}

.admin-logo {
    display: flex;
    gap: 10px;
    align-items: center;
    color: #fff;
    font: 800 20px 'Plus Jakarta Sans';
    padding: 0 12px 30px
}

.admin-logo span {
    display: grid;
    place-items: center;
    width: 35px;
    height: 35px;
    background: var(--gold);
    color: #071b35;
    border-radius: 9px;
    font-size: 12px
}

.admin-sidebar nav {
    display: grid;
    gap: 4px
}

.admin-sidebar nav a {
    padding: 12px;
    border-radius: 9px;
    font-size: 14px
}

.admin-sidebar nav a:hover {
    background: #133b69;
    color: #fff
}

.admin-main {
    padding: 32px;
    max-width: 1400px;
    width: 100%;
    margin: auto
}

.admin-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px
}

.admin-top p {
    margin: 0;
    color: var(--muted);
    font-size: 12px
}

.admin-top h1 {
    margin: 4px 0;
    font-size: 28px
}

.user-chip {
    background: #fff;
    border: 1px solid var(--line);
    padding: 9px 12px;
    border-radius: 9px;
    font-size: 13px
}

.panel {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 15px;
    box-shadow: 0 4px 16px #091e4210;
    padding: 22px
}

.panel-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px
}

.panel-head h2 {
    font-size: 19px;
    margin: 0
}

.table-wrap {
    overflow: auto
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px
}

.data-table th {
    background: #f7f9fc;
    text-align: left;
    color: #718096;
    font-size: 11px;
    text-transform: uppercase
}

.data-table th,
.data-table td {
    padding: 13px;
    border-bottom: 1px solid var(--line)
}

.action-link {
    display: inline-block;
    padding: 6px 8px;
    color: var(--blue);
    font-weight: 700
}

.action-link.danger {
    color: #c62828
}

.badge {
    display: inline-block;
    padding: 5px 8px;
    border-radius: 999px;
    background: #e7f5ec;
    color: #12763f;
    font-size: 11px;
    font-weight: 700
}

.badge.gray {
    background: #edf1f5;
    color: #607083
}

.admin-form {
    max-width: 850px
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px
}

.file-card {
    background: #f7f9fc;
    border: 1px dashed #c7d4e3;
    border-radius: 11px;
    padding: 10px
}

.primary-action {
    background: var(--blue);
    color: #fff;
    border: 0;
    border-radius: 9px;
    padding: 11px 14px;
    font-weight: 700;
    cursor: pointer
}

.success {
    padding: 11px 14px;
    border-radius: 9px;
    background: #e7f5ec;
    color: #12763f;
    margin-bottom: 18px
}

@media(max-width:760px) {
    .shell {
        width: calc(100% - 28px)
    }

    .brand img {
        width: 140px
    }

    .brand span {
        display: none
    }

    .hero {
        padding: 37px 0
    }

    .hero-grid {
        grid-template-columns: 1fr;
        gap: 23px
    }

    .hero h1 {
        font-size: 35px
    }

    .reader-header .shell,
    .reader-toolbar .shell {
        align-items: flex-start;
        flex-direction: column
    }

    .edition-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 13px
    }

    .edition-meta h3 {
        font-size: 18px
    }

    .admin-shell {
        display: block
    }

    .admin-sidebar {
        padding: 17px
    }

    .admin-logo {
        padding-bottom: 14px
    }

    .admin-sidebar nav {
        display: flex;
        overflow: auto
    }

    .admin-sidebar nav a {
        white-space: nowrap
    }

    .admin-main {
        padding: 22px 14px
    }

    .form-grid {
        grid-template-columns: 1fr
    }

    .data-table {
        min-width: 650px
    }
}