/* Global style.css based on user's new template */
:root { 
    --primary-blue: #2D63EE; 
    --neon-green: #28FF3A; 
    --bg-grey: #f3f4f6; 
    --text-dark: #1f2937; 
    --red-kill: #ef4444; 
    --white: #ffffff; 
} 

body {  
    font-family: "MiSans", "PingFang SC", "Microsoft YaHei", sans-serif;  
    font-weight: 600;  
    background-color: var(--bg-grey);  
    color: var(--text-dark);  
    margin: 0; padding: 0; 
    overflow-x: hidden; 
} 

* { box-sizing: border-box; } 

/* 头部导航 */ 
.header {  
    background-color: var(--primary-blue);  
    padding: 15px 5%;  
    display: flex; align-items: center; justify-content: space-between; 
    color: white; font-size: 1.4rem;  
    position: fixed; top: 0; left: 0; right: 0; z-index: 100;  
    box-shadow: 0 4px 15px rgba(45, 99, 238, 0.3); 
} 
.header .logo span { color: var(--neon-green); } 
.header a { color: white; text-decoration: none; font-size: 1rem; margin-left: 15px; opacity: 0.9; } 
.header a:hover { opacity: 1; }

/* 核心布局 */ 
.container-center {  
    display: flex; flex-direction: column; justify-content: center; align-items: center;      
    min-height: 100vh; width: 100%; padding: 80px 20px 20px;  
} 

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 80px 20px 20px;
}

/* 通用卡片样式 (adapted from word-card) */ 
.card {  
    background: var(--white);  
    padding: 30px;  
    border-radius: 30px;  
    width: 100%;  
    max-width: 500px;  
    text-align: center;  
    box-shadow: 0 20px 40px rgba(0,0,0,0.05); 
    animation: cardAppear 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275); 
    position: relative; 
    margin-bottom: 20px;
} 

@keyframes cardAppear { 
    from { opacity: 0; transform: translateY(30px) scale(0.9); } 
    to { opacity: 1; transform: translateY(0) scale(1); } 
} 

/* 按钮基础样式 */
.btn {
    background-color: var(--primary-blue);
    color: white;
    padding: 12px 20px;
    border-radius: 12px;
    font-size: 1.1em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
    font-weight: 600;
    gap: 8px;
    text-decoration: none;
}
.btn:hover { background-color: #1e4bbd; transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-danger { background-color: var(--red-kill); }
.btn-danger:hover { background-color: #dc2626; }

.btn-secondary { background-color: #e5e7eb; color: var(--text-dark); }
.btn-secondary:hover { background-color: #d1d5db; }

/* 操作按钮组 (圆形按钮) */ 
.action-area { 
    margin-top: 20px; 
    display: flex; 
    gap: 20px; 
    width: 100%; 
    justify-content: center; 
} 

.btn-action { 
    width: 60px; 
    height: 60px; 
    border-radius: 50%; 
    border: none; 
    cursor: pointer; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    font-size: 1.4rem; 
    color: white; 
    transition: 0.3s; 
    box-shadow: 0 10px 20px rgba(0,0,0,0.1); 
} 

.btn-action:active { transform: scale(0.9); } 

/* 表单输入框 */
.input {
    width: 100%;
    padding: 15px;
    margin: 10px 0;
    background: #f3f4f6;
    border: 2px solid transparent;
    border-radius: 12px;
    font-size: 1rem;
    transition: 0.3s;
    font-family: inherit;
    font-weight: 600;
    color: var(--text-dark);
}
.input:focus { border-color: var(--primary-blue); background: white; outline: none; }

/* Modal 模态框 */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
}
.modal-content {
    background-color: var(--white);
    padding: 30px;
    border-radius: 30px;
    width: 90%;
    max-width: 400px;
    text-align: center;
    transform: scale(0.7);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    position: relative;
    color: var(--text-dark);
}
.modal.show .modal-content {
    transform: scale(1);
}
.modal h2 { margin-top: 0; color: var(--text-dark); font-size: 1.5rem; }
.close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
    color: #9ca3af;
}
.close-btn:hover { color: var(--text-dark); }

/* Toast 提示 */
.toast-container {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.toast {
    background: var(--text-dark);
    color: var(--white);
    padding: 12px 24px;
    border-radius: 50px;
    font-size: 0.95rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    animation: toastIn 0.3s ease-out forwards;
}
@keyframes toastIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 书籍列表相关 */
.book-item {
    display: flex;
    align-items: center;
    background: var(--white);
    padding: 20px;
    border-radius: 20px;
    margin-bottom: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    transition: transform 0.2s, box-shadow 0.2s;
    text-decoration: none;
    color: var(--text-dark);
}
.book-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
}
.book-cover {
    width: 60px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-blue), #6AA9FA);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: bold;
    color: white;
    margin-right: 20px;
    box-shadow: 0 4px 10px rgba(45, 99, 238, 0.3);
}
.book-info { flex: 1; text-align: left; }
.book-title { font-size: 1.2rem; font-weight: bold; margin-bottom: 5px; }
.book-meta { font-size: 0.85rem; color: #6b7280; }

.book-actions {
    display: flex;
    gap: 10px;
}
.book-action-btn {
    background: #f3f4f6;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #4b5563;
    cursor: pointer;
    transition: 0.2s;
}
.book-action-btn:hover { background: var(--primary-blue); color: white; }
.book-action-btn.delete:hover { background: var(--red-kill); }

/* 移动端适配 */ 
@media (max-width: 480px) { 
    .card { padding: 30px 20px; } 
    .btn-action { width: 50px; height: 50px; font-size: 1.2rem; } 
    .header { font-size: 1.2rem; }
} 
