@media screen and (max-width: 768px) {
    body{
        display: flex;
        flex-direction: column;
        min-height: 100vh;
    }
    .archive-layout {
        display: flex !important;
        flex-direction: column;
        flex:1 1 auto;
        height: auto;
    }
    footer{
        position: relative;
        z-index: 1;
    }

    .sidebar {
        position: fixed !important;
        top: 0;
        left: 0;
        width: 240px;
        height: 100vh;
        background: #111 !important;
        z-index: 999;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    .sidebar.open {
        transform: translateX(0%);
    }

    .sidebar-toggle-btn {
        font-family: Georgia, serif;
        display: block !important;
        position: fixed;
        top: 16px;
        left: 16px;
        z-index: 1000;
        background: #333;
        color: #fff;
        padding: 6px 10px;
        font-size: 14px;
        border: 1px solid #666;
        border-radius: 4px;
    }

    .sidebar-toggle-btn:hover {
        text-shadow:
            0 0 1px #0ff,
            0 0 4px #0ff;
        color: #ccc;
        cursor:
            url("./assets/aerored/aero_link.cur"), pointer;
    
    }

    .info {
        flex: 1;
        width: 100%;
        padding: 12px;
        box-sizing: border-box;
        overflow: visible;
    }

    .content {
        width: 100%;
        padding: 12px;
    }
    #home-section {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }
    #home-section a{
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }
    #home-section a img{
        width: 50% !important;
    }
}


html,
body {
    margin: 0;
    height: 100%;
    font-family: Georgia, serif;
    background: #1e1b1f;
    color: #f0f0f0;
}

body {
    cursor:
        url("./assets/aerored/aero_arrow.cur"), auto;

}

a {
    cursor:
        url("./assets/aerored/aero_link.cur"), pointer;
}

.archive-layout {
    display: grid;
    grid-template-columns: 200px 1fr 300px;
    height: calc(100vh - 40px);
    overflow: hidden;

    background-image: url("./bg.webp");
}

.sidebar {
    background: #11111180;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

#sidebar-toggle {
    display: none;
}

#navi {
    padding: 20px;
}

.sidebar button {
    font-family: Georgia, serif;
    border: none;
    padding: 10px;
    cursor: pointer;
    color: #79836C;
    display: block;
    background-color: transparent;
}

.sidebar button:hover {
    text-shadow:
        0 0 1px #0ff,
        0 0 4px #0ff;
    color: #ccc;
    cursor:
        url("./assets/aerored/aero_link.cur"), pointer;

}

.sidebar p {
    text-align: center;
    margin-bottom: 0;
}

#safe {
    position: absolute;
    bottom: 10%;
    left: 0;
    width: 100%;
    pointer-events: none;
    /* 不挡菜单 */
}

.content {
    padding: 20px;
    overflow-y: auto;
}

.section-block {
    display: block;
}

.hidden {
    display: none !important;
}

#home-section img {
    width: 50%;
}

#home-section p {
    width: 50%;
}

#home-section a img {
    width: 200px;
}

#resource-title {
    font-size: 1.6rem;
    margin-bottom: 14px;
}

/* 子页面标题 */
h1 {
    color: #E0DFC6;
}

.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
    padding: 10px;
}

.card {
    height: 180px;
    aspect-ratio: 1/1;
    background: transparent;
    padding: 6px;
    text-align: center;
    color: #ccc;
    font-size: 0.85rem;

    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    box-sizing: border-box;
}

.img-frame {
    width: 100%;
    height: 120px;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.img-frame img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.img-frame img:hover {
    transform: scale(1.05);
}

.filename {
    font-weight: bold;
    color: #eee;
    font-size: 0.8rem;
    margin-top: 6px;
}

.desc {
    font-size: 0.7rem;
    color: #999;
    margin-top: 4px;
    line-height: 1.3;
}


/*right*/

.info {
    padding: 16px;
    font-size: 0.9rem;
    color: #aaa;
    position: relative;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

#toggle-info {
    display: none;
}

.info p > a > img, .info p > img {
    display: block;
    margin: 0 auto;
}  

pre.code-block {
    background: #000000;
    border: 1px solid #445c53;
    padding: 8px 12px;
    font-family: "Courier New", monospace;
    font-size: 13px;
    color: #e2fff5;
    overflow-x: auto;
    max-width: 100%;
    line-height: 1.4;
    white-space: pre-wrap;  
    word-break: break-word; 
    box-shadow: inset 0 0 4px rgba(0,0,0,0.1);
    margin: 10px 0;
    
    text-align: left;
    height: 80px;
    box-sizing: border-box;
  }
  
  .code-wrapper {
    position: relative;
    max-width: 100%;
  }
  
  .copy-btn {
    position: absolute;
    bottom: 6px;
    left: 6px;
    font-size: 12px;
    background: #333;
    color: white;
    border: none;
    padding: 4px 8px;
    font-family: monospace;
    z-index: 2;
    cursor:url("./assets/aerored/aero_link.cur"), pointer;
  }
  
  .copy-btn:hover {
    background: #555;
  }

.footer {
    height: 40px;
    background: #000;
    color: #999;
    text-align: center;
    line-height: 40px;
    font-size: 0.85rem;
}

/* ===== text effect ===== */
.hallucinate {
    color: #eee;
    position: relative;
    text-shadow:
        0 0 0.5px #ff0051,
        0.25px 0.25px 0 #1bf9ff,
        -0.5px -0.5px 0 #b7ff39,
        0 0 10px rgba(0, 255, 150, .4);
    mix-blend-mode: lighten;
    filter: contrast(1.2) saturate(1.4);
}

.dim-hallucinate {
    color: #b0b0b0;
    position: relative;
    text-shadow:
        0 0 0.5px #ff005180,
        0.25px 0.25px 0 #1bf9ff80,
        -0.5px -0.5px 0 #b7ff3980,
        0 0 10px rgba(0, 255, 150, .4);
    mix-blend-mode: lighten;
    filter: brightness(1.1) contrast(0.9);
    mix-blend-mode: screen;
}