@font-face {
    font-family: 'jf_dot_ayu';
    src: url('/static/fonts/JF-Dot-Ayu18.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}
@font-face {
    font-family: 'not-jam-glasgow';
    src: url('/static/fonts/Not\ Jam\ Glasgow\ 13.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}
@font-face {
    font-family: 'yantramanav';
    src: url('/static/fonts/yantramanav-regular-webfont.woff') format('woff');
    font-weight: normal;
    font-style: normal;
}
title {
    font-family: "jf_dot_ayu";
    color:aquamarine;
}

html, body {
    height: 100%;
    margin: 0;
    overflow: visible;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-color: #151616;
    margin: 0;
}

footer {
    text-align: center;
}

h1, h2, h3, h4, h5, p, a{
    font-family: "jf_dot_ayu";
    color:aquamarine;
}
button {
    font-family: "jf_dot_ayu";
    color: black;
    background-color: aquamarine;
}

/* height of the fixed top bar; pages leave this much room at the top */
:root { --nav-h: 42px; }

#navbar {
    display: flex;
    align-items: center;
    background-color: #333;
    background-position: left top;
    overflow: hidden;
    position: fixed;
    top: 0;
    width: 100%;
    opacity: 0.9f;
    z-index: 1000;
    min-height: var(--nav-h);
    box-shadow: 0 4px 8px #0000005d;
}

.navbar {
    position: relative;
    z-index: 1000;
}

#navbar-right {
    display: flex;
    align-items: center;
    position: absolute;
    margin-left: auto;
    right: 0;
}

#navbar-pfp img {
    height: 40px;
    width: 40px;
    object-fit: cover;
    overflow: hidden;
    max-height: 100%;
    border-radius: 15%;
    display: block;
    padding: 0;
    margin-right: 6px;
    margin-left: 4px;
}

#navbar a {
    display: block;
    color: #f2f2f2;
    text-align: center;
    padding: 10px 20px;
    text-decoration: none;
    font-size: 17px;
}

#navbar a:hover {
    background-color: #ddd;
    color: black;
}

#navbar a.active {
    background-color: #04AA6D;
    color: white;
}

#navbar-button {
    background-color: #333;
    color: #ddd;
    border: none;
    padding: 10px 20px;
    font-size: 17px;
    cursor: pointer;
}

#navbar-button:hover {
    background-color: #ddd;
    color: black;
}

.vertical-line {
    background-image: url('/static/images/vertical-line.png');
    height: var(--nav-h);
    display: inline-block;
    padding-left: 2px;
    padding-right: 2px;
}

/* Sticky class */
.sticky {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 1000;
}

.sticky + .main-content {
    padding-top: var(--nav-h);
}

.main-content {
    flex: 1;
    padding: 0px;
}

footer {
    background-color: #333;
    color: #ddd;
    text-align: center;
    padding: 10px;
}

/* ── Profile button + popup ── */
#navbar-pfp {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    display: block;
}
#navbar-pfp:focus-visible { outline: 2px solid aquamarine; outline-offset: 2px; }

/* ── Site modals (login + profile), same look as the reader's "Exclusive Content" modal ── */
.site-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: center;
    padding: 16px;
    box-sizing: border-box;
}
.site-modal .site-modal-content {
    position: relative;
    border: 1px solid rgba(127, 255, 212, 0.192);
    background-color: #151616;
    padding: 20px;
    border-radius: 1px;
    text-align: center;
    width: 340px;
    max-width: 100%;
    max-height: calc(100vh - 32px);
    max-height: calc(100svh - 32px);   /* the part of the screen that's always visible on phones */
    overflow-y: auto;
    box-sizing: border-box;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    font-family: "jf_dot_ayu";
}
.site-modal .site-modal-content h2 { margin: 4px 0 12px; }
.site-modal .site-modal-content p { font-size: 14px; }
.site-modal .close {
    position: absolute;
    top: 6px;
    right: 10px;
    background: none;
    border: none;
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    line-height: 1;
    cursor: pointer;
    padding: 0;
}
.site-modal .close:hover, .site-modal .close:focus-visible { color: #ddd; }
.site-modal .login-button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #007bff;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    margin: 8px 0 12px;
}
.site-modal .login-button:hover { background-color: #0069d9; }
.login-perks {
    text-align: left;
    margin: 0 0 12px 0;
    padding-left: 20px;
    color: #ddd;
    font-size: 13px;
    line-height: 1.6;
}
.login-fineprint { font-size: 11px !important; color: #999; margin: 6px 0; }
.login-fineprint a { color: aquamarine; }
.profile-modal-content { text-align: left !important; width: 360px !important; }
.profile-modal-content .pp-head { padding-right: 24px; }
.pp-head { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.pp-avatar { width: 56px; height: 56px; border-radius: 15%; object-fit: cover; }
.pp-name { color: aquamarine; font-size: 16px; }
.pp-status { font-size: 12px; margin-top: 4px; color: #aaa; }
.pp-status-active_patron { color: #7CFC9A; }
.pp-status-owner { color: #ffd43b; }
.pp-status-declined_patron { color: #ffb347; }
.pp-stats { margin: 0 0 12px 0; border-top: 1px solid #333; }
.pp-stats div { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border-bottom: 1px solid #333; }
.pp-stats dt { color: #999; font-size: 12px; }
.pp-stats dd { margin: 0; color: #eee; font-size: 12px; text-align: right; }
.pp-note { font-size: 11px; color: #ffb347; margin: 0 0 10px 0; }
.pp-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.pp-actions form { margin: 0; }
.pp-btn {
    display: inline-block;
    font-family: "jf_dot_ayu";
    font-size: 12px;
    padding: 6px 10px;
    border: 1px solid #555;
    background-color: #2a2c2c;
    color: #ddd;
    text-decoration: none;
    cursor: pointer;
}
.pp-btn:hover { background-color: #ddd; color: black; }
.pp-btn-primary { background-color: aquamarine; color: black; border-color: aquamarine; }

/* ── Admin "preview as" banner ── */
#preview-banner {
    position: fixed;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1200;
    background: #ffd43b;
    color: black;
    font-family: "jf_dot_ayu";
    font-size: 13px;
    padding: 8px 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.5);
    display: flex;
    gap: 10px;
    align-items: center;
}
#preview-banner strong { color: black; }
#preview-banner button { background: black; color: #ffd43b; border: none; padding: 4px 10px; cursor: pointer; }
.site-modal .modal-text-button {
    background: none;
    border: none;
    color: #999;
    text-decoration: underline;
    cursor: pointer;
    font-size: 12px;
    font-family: "jf_dot_ayu";
}
.site-modal .modal-text-button:hover { color: #ddd; }

/* Pixel-art lock icon (templates/_icons.html): 1em tall, takes the text colour */
.px-lock {
    height: 1em;
    width: auto;
    vertical-align: -0.12em;
    image-rendering: pixelated;
    flex-shrink: 0;
}


/* staging.knuxy.art only: a reminder that this is the test copy */
.staging-badge {
    position: fixed; left: 8px; bottom: 8px; z-index: 10000; pointer-events: none;
    font-family: "jf_dot_ayu", monospace; font-size: 11px; letter-spacing: 2px;
    color: #1a1a1a; background: #ffd43b; padding: 3px 8px; border-radius: 2px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.6); opacity: 0.9;
}

/* ── Phones: a bigger, thumb-friendly top bar ── */
@media (max-width: 700px) {
    :root { --nav-h: 56px; }
    #navbar { flex-wrap: nowrap; }
    #navbar a, #navbar-button {
        display: flex; align-items: center; justify-content: center;
        height: var(--nav-h); box-sizing: border-box;
        padding: 0 12px; font-size: 19px; letter-spacing: 0.5px;
    }
    #navbar > a { flex: 1 1 auto; }          /* HOME / GALLERY / COMICS share the width */
    #navbar .vertical-line { padding: 0 1px; }
    #navbar-right { position: static; margin-left: 0; flex: 0 0 auto; }
    #navbar-pfp img { height: 44px; width: 44px; }
}
@media (max-width: 380px) {
    #navbar a, #navbar-button { padding: 0 8px; font-size: 17px; letter-spacing: 0; }
}

/* Phones: text boxes under 16px make the browser zoom in when you tap them */
@media (max-width: 700px) {
    input:not([type="checkbox"]):not([type="radio"]):not([type="file"]), select, textarea { font-size: 16px !important; }
}
