/* Apple ID Hub Style */

/* 基础样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

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

/* 视图样式 */
.view {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 验证页面样式 */
#verify-view {
    background-color: #f5f7fa;
}

.verify-form {
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    text-align: center;
    min-width: 300px;
}

.verify-form h1 {
    margin-bottom: 20px;
    color: #1a73e8;
}

.verify-form input {
    width: 100%;
    padding: 12px;
    margin-bottom: 20px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.verify-form input:focus {
    outline: none;
    border-color: #1a73e8;
    box-shadow: 0 0 0 2px rgba(26, 115, 232, 0.2);
}

/* 主页面样式 */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e0e0e0;
}

header h1 {
    color: #1a73e8;
    font-size: 24px;
}

/* 分组容器样式 */
.group-container {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    overflow: hidden;
}

.group-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background-color: #f8f9fa;
    border-bottom: 1px solid #e0e0e0;
}

.group-header h2 {
    font-size: 18px;
    color: #333;
    margin: 0;
}

.group-actions {
    display: flex;
    gap: 10px;
}

.group-content {
    padding: 20px;
}

/* 搜索容器样式 */
.search-container {
    margin-bottom: 20px;
}

.search-input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.search-input:focus {
    outline: none;
    border-color: #1a73e8;
    box-shadow: 0 0 0 2px rgba(26, 115, 232, 0.2);
}

/* 账号列表样式 */
.accounts-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.group-stats {
    background-color: #f8f9fa;
    padding: 10px 15px;
    border-radius: 4px;
    font-size: 14px;
    color: #666;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 15px;
}

.account-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 15px;
    transition: box-shadow 0.2s ease;
}

.account-card:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.account-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 15px;
}

.account-info {
    flex: 1;
}

.account-username {
    font-size: 16px;
    font-weight: 500;
    color: #333;
    margin-bottom: 5px;
}

.account-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    font-size: 12px;
    color: #666;
}

.account-meta span {
    background-color: #f0f0f0;
    padding: 2px 8px;
    border-radius: 12px;
}

.account-actions {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

/* 按钮样式 */
.btn {
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-primary {
    background-color: #1a73e8;
    color: white;
}

.btn-primary:hover {
    background-color: #1557b0;
}

.btn-secondary {
    background-color: #f0f0f0;
    color: #333;
}

.btn-secondary:hover {
    background-color: #e0e0e0;
}

.btn-danger {
    background-color: #d93025;
    color: white;
}

.btn-danger:hover {
    background-color: #b32118;
}

.btn-success {
    background-color: #34a853;
    color: white;
}

.btn-success:hover {
    background-color: #2d8e49;
}

.btn-sm {
    padding: 4px 12px;
    font-size: 12px;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* 折叠/展开按钮样式 */
.toggle-btn {
    background: none;
    border: none;
    color: #1a73e8;
    cursor: pointer;
    font-size: 14px;
    padding: 5px 10px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.toggle-btn:hover {
    background-color: rgba(26, 115, 232, 0.1);
}

/* 空状态样式 */
.empty-state {
    text-align: center;
    padding: 30px;
    color: #666;
    background-color: #f8f9fa;
    border-radius: 6px;
    border: 1px dashed #ddd;
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
    margin-right: 5px;
    vertical-align: middle;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Toast 提示样式 */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: 4px;
    color: white;
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    display: none;
    transition: transform 0.3s ease;
}

.toast-success {
    background-color: #34a853;
}

.toast-error {
    background-color: #d93025;
}

.toast-warning {
    background-color: #fbbc05;
    color: #333;
}

.toast-info {
    background-color: #1a73e8;
}

/* 管理后台样式 */
.admin-section {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 20px;
    margin-bottom: 30px;
}

.admin-section h2 {
    font-size: 20px;
    margin-bottom: 20px;
    color: #333;
    border-bottom: 2px solid #1a73e8;
    padding-bottom: 10px;
}

.admin-section h3 {
    font-size: 16px;
    margin-bottom: 15px;
    color: #555;
}

.admin-form {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.form-row {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    align-items: center;
    margin-bottom: 15px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
    flex: 1;
    min-width: 200px;
}

.form-group label {
    font-size: 14px;
    font-weight: 500;
    color: #333;
}

.form-group input,
.form-group select {
    padding: 8px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #1a73e8;
    box-shadow: 0 0 0 2px rgba(26, 115, 232, 0.2);
}

.quick-buttons {
    display: flex;
    gap: 5px;
    margin-top: 5px;
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

/* 表格样式 */
.admin-table-container {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.admin-table th,
.admin-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.admin-table th {
    background-color: #f8f9fa;
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.admin-table td {
    font-size: 14px;
    color: #555;
}

.admin-table tbody tr:hover {
    background-color: #f8f9fa;
}

.admin-table tbody tr:last-child td {
    border-bottom: none;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .group-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .group-actions {
        width: 100%;
        justify-content: flex-start;
    }
    
    .account-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .account-actions {
        flex-direction: row;
        width: 100%;
        justify-content: flex-start;
    }
    
    .form-row {
        flex-direction: column;
        align-items: stretch;
    }
    
    .form-group {
        width: 100%;
    }
    
    .admin-table {
        font-size: 12px;
    }
    
    .admin-table th,
    .admin-table td {
        padding: 8px 10px;
    }
}
