.password-list { display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; margin-bottom: 24px; } /* 大屏幕(1600px以上)- 5列 */ @media (min-width: 1600px) { .password-list { grid-template-columns: repeat(5, 1fr); } } /* 中大屏(1200px-1599px)- 4列 */ @media (max-width: 1599px) { .password-list { grid-template-columns: repeat(4, 1fr); } } /* 中等屏幕(900px-1199px)- 3列 */ @media (max-width: 1199px) { .password-list { grid-template-columns: repeat(3, 1fr); } } /* 小屏幕(768px以下,手机端)- 2列 */ @media (max-width: 768px) { .password-list { grid-template-columns: repeat(2, 1fr); gap: 12px; } } /* 超小屏幕(480px以下)- 2列,更小的间距 */ @media (max-width: 480px) { .password-list { grid-template-columns: repeat(2, 1fr); gap: 10px; } } .password-card { background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 255, 248, 0.95) 100%); border-radius: 14px; padding: 12px 12px 10px; box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(76, 175, 80, 0.1); transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); backdrop-filter: blur(10px); border: 1px solid rgba(200, 230, 201, 0.3); position: relative; overflow: hidden; display: flex; flex-direction: column; height: 100%; min-height: 0; } .password-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px; background: linear-gradient(90deg, #66bb6a 0%, #4caf50 50%, #66bb6a 100%); transform: scaleX(0); transition: transform 0.3s; } .password-card:hover { transform: translateY(-8px) scale(1.02); box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12), 0 4px 12px rgba(76, 175, 80, 0.15); border-color: rgba(76, 175, 80, 0.5); } .password-card:hover::before { transform: scaleX(1); } .card-header { display: flex; align-items: flex-start; gap: 8px; margin-bottom: 8px; padding-bottom: 8px; border-bottom: 1px solid rgba(232, 245, 233, 0.6); } .card-logo-wrapper { flex-shrink: 0; width: 40px; height: 40px; border-radius: 10px; background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%); display: flex; align-items: center; justify-content: center; padding: 5px; box-shadow: 0 2px 8px rgba(76, 175, 80, 0.15); transition: all 0.3s; } .password-card:hover .card-logo-wrapper { transform: scale(1.1) rotate(5deg); box-shadow: 0 4px 12px rgba(76, 175, 80, 0.25); } .card-logo { width: 100%; height: 100%; object-fit: contain; border-radius: 8px; } .card-title-section { flex: 1; display: flex; flex-direction: column; gap: 0; min-width: 0; } .card-title-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; } .card-title { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; flex: 1; min-width: 0; } .card-type { font-size: 14px; font-weight: 700; color: #1b5e20; line-height: 1.25; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; } .card-account-type { font-size: 11px; color: #4caf50; background: linear-gradient(135deg, rgba(102, 187, 106, 0.15) 0%, rgba(76, 175, 80, 0.1) 100%); padding: 4px 12px; border-radius: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; border: 1px solid rgba(76, 175, 80, 0.2); } .website-link { font-size: 13px; color: #4caf50; text-decoration: none; transition: all 0.2s; display: inline-flex; align-items: center; gap: 6px; margin-top: 4px; word-break: break-all; } .website-link svg { flex-shrink: 0; display: block; } .website-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; } .website-link:hover { color: #2e7d32; text-decoration: underline; } .website-link:hover svg { transform: translateX(2px); } .card-actions { display: flex; gap: 6px; } .edit-button, .delete-button { background: rgba(255, 255, 255, 0.8); border: 1px solid rgba(76, 175, 80, 0.2); font-size: 16px; cursor: pointer; padding: 5px; border-radius: 6px; transition: all 0.2s; display: flex; align-items: center; justify-content: center; color: #4caf50; } .edit-button:hover { background: rgba(76, 175, 80, 0.15); border-color: #4caf50; transform: scale(1.1); color: #2e7d32; } .delete-button { color: #f44336; border-color: rgba(244, 67, 54, 0.2); } .delete-button:hover { background: rgba(244, 67, 54, 0.1); border-color: #f44336; transform: scale(1.1); color: #d32f2f; } .card-content { display: flex; flex-direction: column; gap: 4px; padding-top: 0; flex: 1; min-height: 0; } .info-row { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; line-height: 1.3; position: relative; padding: 3px 7px; background: rgba(248, 255, 248, 0.5); border-radius: 6px; transition: all 0.2s; border: 1px solid transparent; min-height: 0; overflow: hidden; } .info-row:hover { background: rgba(232, 245, 233, 0.7); border-color: rgba(200, 230, 201, 0.5); transform: translateX(4px); } .info-row:hover .copy-button { opacity: 1; } .copy-button { background: rgba(76, 175, 80, 0.1); border: 1px solid rgba(76, 175, 80, 0.2); cursor: pointer; padding: 3px 6px; border-radius: 5px; transition: all 0.2s; flex-shrink: 0; color: #4caf50; min-width: 28px; height: 24px; display: flex; align-items: center; justify-content: center; opacity: 0.7; } .copy-button:hover { background: rgba(76, 175, 80, 0.2); border-color: #4caf50; transform: scale(1.1); opacity: 1; } .copy-button:active { transform: scale(0.95); } .copy-button svg { display: block; } .info-label { color: #555; font-weight: 700; min-width: 46px; flex-shrink: 0; font-size: 11px; } .info-value { color: #333; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; font-weight: 600; } .password-value { font-weight: 700; color: #2e7d32; } .info-link { color: #4caf50; text-decoration: none; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; font-weight: 600; } .info-link:hover { text-decoration: underline; } .tags { display: inline-block; background: linear-gradient(135deg, #c8e6c9 0%, #a5d6a7 100%); padding: 4px 10px; border-radius: 12px; font-size: 12px; } /* 卡片底部标签:贴在卡片底部,内容少时留白在中间区域 */ .card-tags { flex-shrink: 0; margin-top: 6px; padding: 4px 7px; border-top: 1px solid rgba(232, 245, 233, 0.6); display: flex; align-items: center; gap: 4px; flex-wrap: wrap; background: linear-gradient(135deg, rgba(200, 230, 201, 0.3) 0%, rgba(165, 214, 167, 0.2) 100%); border-radius: 6px; } .card-tag { display: inline-block; background: rgba(76, 175, 80, 0.12); border: 1px solid rgba(76, 175, 80, 0.25); color: #4caf50; font-size: 10px; font-weight: 700; padding: 1px 6px; border-radius: 8px; white-space: nowrap; } /* ===== 分页 ===== */ .pagination { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 16px 0 30px; flex-wrap: wrap; } .page-btn { min-width: 36px; height: 36px; padding: 0 10px; border: 1px solid rgba(76, 175, 80, 0.3); border-radius: 8px; background: rgba(255, 255, 255, 0.9); color: #4caf50; font-size: 14px; font-weight: 600; cursor: pointer; transition: all 0.2s; display: flex; align-items: center; justify-content: center; } .page-btn:hover:not(:disabled) { background: rgba(76, 175, 80, 0.12); border-color: #4caf50; transform: translateY(-1px); } .page-btn.active { background: linear-gradient(135deg, #66bb6a, #4caf50); color: #fff; border-color: #4caf50; box-shadow: 0 3px 10px rgba(76, 175, 80, 0.35); } .page-btn:disabled { opacity: 0.35; cursor: not-allowed; } .page-ellipsis { color: #aaa; font-size: 14px; padding: 0 4px; } .page-info { font-size: 12px; color: #888; margin-left: 8px; white-space: nowrap; } @media (max-width: 768px) { .pagination { gap: 4px; margin: 12px 0 20px; } .page-btn { min-width: 32px; height: 32px; font-size: 13px; padding: 0 8px; } .page-info { width: 100%; text-align: center; margin-left: 0; margin-top: 4px; } } .empty-state { text-align: center; padding: 80px 20px; background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 255, 248, 0.95) 100%); border-radius: 20px; box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1); grid-column: 1 / -1; } .empty-icon { color: #4caf50; margin: 0 auto 20px; opacity: 0.6; display: flex; align-items: center; justify-content: center; } .empty-icon svg { display: block; } .empty-state p { color: #666; font-size: 18px; margin-bottom: 10px; font-weight: 600; } .empty-hint { font-size: 14px; color: #999; } @media (max-width: 768px) { .password-card { padding: 10px 10px 8px; border-radius: 12px; } .card-header { gap: 7px; margin-bottom: 7px; padding-bottom: 7px; } .card-logo-wrapper { width: 36px; height: 36px; } .card-type { font-size: 13px; } .card-account-type { font-size: 10px; padding: 3px 8px; } .card-content { gap: 3px; } .info-row { font-size: 11px; padding: 3px 6px; gap: 5px; } .info-label { min-width: 42px; font-size: 10px; } .copy-button { padding: 2px 5px; min-width: 26px; height: 22px; } .copy-button svg { width: 14px; height: 14px; } .card-title-row { gap: 4px; align-items: flex-start; } .edit-button, .delete-button { padding: 2px; width: 24px; height: 24px; box-sizing: border-box; border-radius: 5px; } .edit-button svg, .delete-button svg { width: 13px; height: 13px; } .card-actions { flex-direction: column; align-items: center; gap: 3px; flex-shrink: 0; } .card-tags { margin-top: 5px; padding: 3px 6px; font-size: 9px; } } @media (max-width: 480px) { .password-card { padding: 9px 9px 7px; border-radius: 11px; } .card-header { gap: 6px; margin-bottom: 6px; padding-bottom: 6px; } .card-logo-wrapper { width: 34px; height: 34px; } .card-type { font-size: 12px; } .card-account-type { font-size: 9px; padding: 2px 6px; } .card-content { gap: 2px; } .info-row { font-size: 10px; padding: 2px 5px; gap: 4px; } .info-label { min-width: 40px; font-size: 9px; } .empty-state { padding: 60px 15px; } .empty-icon svg { width: 48px; height: 48px; } .empty-state p { font-size: 16px; } .empty-hint { font-size: 13px; } .card-title-row { gap: 3px; align-items: flex-start; } .edit-button, .delete-button { width: 22px; height: 22px; padding: 1px; border-radius: 4px; } .edit-button svg, .delete-button svg { width: 12px; height: 12px; } .card-actions { gap: 2px; } .card-tags { margin-top: 4px; padding: 2px 5px; font-size: 8px; } }