/* style_gallery.css - 画廊/档案风格重新设计 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Helvetica Neue", Arial, sans-serif;
    background-color: #ffffff;
    color: #1d1d1f;
    -webkit-font-smoothing: antialiased;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    letter-spacing: -0.011em;
}

@media (min-width: 768px) {
    body {
        flex-direction: row;
    }
}

/* 侧边栏导航 */
.header {
    width: 100%;
    background: #fff;
    padding: 40px;
    border-bottom: 1px solid #000;
    z-index: 100;
}

@media (min-width: 768px) {
    .header {
        width: 280px;
        height: 100vh;
        position: fixed;
        left: 0;
        top: 0;
        border-bottom: none;
        border-right: 1px solid rgba(0, 0, 0, 0.05);
        /* Softer divider */
        padding: 60px 40px;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        background: rgba(255, 255, 255, 0.8);
        backdrop-filter: saturate(180%) blur(20px);
    }
}

.logo h1 {
    font-size: 24px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    line-height: 1.2;
    margin-bottom: 60px;
}

.nav {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.nav-link {
    font-size: 15px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    text-decoration: none;
    color: #1d1d1f;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0.6;
}

.nav-link:hover {
    opacity: 1;
    color: #0071e3;
    padding-left: 5px;
}

.nav-link.active {
    opacity: 1;
    font-weight: 600;
    color: #0071e3;
}

.nav-link.italic {
    font-style: italic;
    text-transform: none;
}

.nav-sub {
    margin: 10px 0 10px 15px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.nav-sub a {
    font-size: 13px;
    color: #666;
    text-decoration: none;
}

/* 底部信息与控制 */
.footer-info {
    margin-top: auto;
}

.nav-controls {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

/* 切换开关样式 */
.toggle-switch {
    width: 40px;
    height: 20px;
    background: #e0e0e0;
    border-radius: 20px;
    position: relative;
    cursor: pointer;
    transition: background 0.3s ease;
}

.toggle-switch.active {
    background: #000;
}

.toggle-circle {
    width: 16px;
    height: 16px;
    background: white;
    border-radius: 50%;
    position: absolute;
    top: 2px;
    left: 2px;
    transition: transform 0.3s ease;
}

.toggle-switch.active .toggle-circle {
    transform: translateX(20px);
}

#paid-courses-link,
#brain-research-link {
    display: none;
}

#paid-courses-link.active,
#brain-research-link.active {
    display: block;
}

/* 主内容区域 */
.main-content {
    flex: 1;
    padding: 40px;
}

@media (min-width: 768px) {
    .main-content {
        margin-left: 280px;
        padding: 80px 60px;
    }
}

/* 排版与元素 */
h2 {
    font-size: 14px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    border-bottom: 1px solid #000;
    padding-bottom: 8px;
    margin-bottom: 40px;
}

.page-title {
    font-size: 48px;
    font-style: italic;
    margin-bottom: 40px;
    font-weight: normal;
}

/* 灰度图片 */
img {
    filter: grayscale(100%);
    transition: filter 0.8s ease;
}

img:hover {
    filter: grayscale(0%);
}

/* 管理入口 - 极简覆盖层 */
#admin-controls {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
}

.admin-btn {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #000;
    border: none;
    cursor: pointer;
    transition: transform 0.3s, background 0.3s;
    padding: 0;
}

.admin-btn:hover {
    transform: scale(1.5);
    background: #666;
}

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(20px);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-content {
    width: 100%;
    max-width: 440px;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    background: rgba(255, 255, 255, 0.85);
    padding: 40px;
    border-radius: 32px;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    animation: modalScale 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

/* 隐藏滚动条但保留功能 - 更加 Apple 风格 */
.modal-content::-webkit-scrollbar {
    width: 4px;
}

.modal-content::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 10px;
}

@keyframes modalScale {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(20px);
    }

    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.modal-title {
    font-size: 20px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    margin-bottom: 40px;
    text-align: center;
}

.form-group {
    margin-bottom: 30px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid #000;
    padding: 10px 0;
    color: #000;
    font-size: 16px;
    font-family: inherit;
    outline: none;
}

.submit-btn {
    width: 100%;
    padding: 16px;
    background: #0071e3;
    color: #fff;
    border: none;
    border-radius: 12px;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(0, 113, 227, 0.2);
}

.submit-btn:hover {
    background: #0077ed;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 113, 227, 0.3);
}

.submit-btn:active {
    transform: translateY(0);
}

/* 固定布局容器 */
.container {
    width: 100%;
    max-width: 1200px;
}

/* 移动端侧边栏切换 */
#menu-btn {
    display: none;
}

@media (max-width: 767px) {
    #menu-btn {
        display: block;
        position: absolute;
        top: 40px;
        right: 40px;
        background: none;
        border: none;
        font-size: 24px;
        cursor: pointer;
    }
}