*{box-sizing:border-box;margin:0;padding:0}body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;background:#f0f2f5;color:#1a1a1a}nav{display:flex;justify-content:space-between;align-items:center;padding:16px 32px;background:#fff;border-bottom:1px solid #e5e7eb}.brand{font-weight:700;font-size:1rem}nav div{display:flex;align-items:center;gap:24px}nav a{color:#4a7cf6;text-decoration:none;font-size:.95rem}nav button{background:none;border:none;color:#4a7cf6;font-size:.95rem;cursor:pointer;padding:0}.page{min-height:100vh;background:#f0f2f5}.content{max-width:720px;margin:0 auto;padding:40px 24px}.auth-page{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:60px 24px;text-align:center;min-height:100vh;background:#f0f2f5}.auth-page h1{font-size:2rem;font-weight:800;margin-bottom:8px;color:#1a1a1a}.auth-page>p{color:#6b7280;margin-bottom:32px}.card{background:#fff;border-radius:12px;padding:40px;width:100%;max-width:600px;box-shadow:0 2px 12px #00000014;text-align:left}.field{margin-bottom:20px}.field label{display:block;font-size:.9rem;color:#374151;margin-bottom:6px}.field input,.field select{width:100%;padding:12px 16px;border:1px solid #d1d5db;border-radius:8px;font-size:.95rem;outline:none;background:#fff}.field input:focus,.field select:focus{border-color:#4a7cf6}.card>button{width:100%;padding:14px;background:#4a7cf6;color:#fff;border:none;border-radius:8px;font-size:1rem;cursor:pointer;margin-top:8px}.card>p{text-align:center;margin-top:16px;color:#6b7280;font-size:.9rem}.card>p a{color:#4a7cf6;text-decoration:none}.dashboard-header{display:flex;justify-content:space-between;align-items:flex-start;margin-bottom:32px}.dashboard-header h1{font-size:1.8rem;font-weight:800}.dashboard-header p{color:#6b7280;margin-top:4px}.add-btn{padding:10px 20px;border:2px solid #4a7cf6;background:#fff;color:#4a7cf6;border-radius:8px;font-size:.95rem;cursor:pointer;white-space:nowrap}.habit-card{background:#fff;border-radius:12px;padding:20px 24px;margin-bottom:16px;display:flex;justify-content:space-between;align-items:center;box-shadow:0 1px 4px #0000000f}.habit-card h3{font-size:1rem;font-weight:700;margin-bottom:4px}.habit-card p{color:#6b7280;font-size:.85rem;margin-bottom:2px}.complete-btn{padding:10px 20px;background:#4a7cf6;color:#fff;border:none;border-radius:8px;cursor:pointer;font-size:.9rem;white-space:nowrap}.complete-btn:disabled{background:#d1d5db;color:#6b7280}.habit-actions{display:flex;flex-direction:column;gap:8px;align-items:flex-end}.delete-btn{padding:6px 16px;background:#fff;color:#ef4444;border:1px solid #ef4444;border-radius:8px;cursor:pointer;font-size:.85rem}.delete-btn:hover{background:#ef4444;color:#fff}.empty-state{text-align:center;padding:60px 24px;color:#6b7280}.empty-state p:first-child{font-size:3rem;margin-bottom:12px}.empty-state h3{font-size:1.2rem;font-weight:700;color:#1a1a1a;margin-bottom:8px}.toast{position:fixed;bottom:32px;left:50%;transform:translate(-50%);background:#22c55e;color:#fff;padding:14px 28px;border-radius:12px;font-weight:600;font-size:1rem;box-shadow:0 4px 12px #00000026;z-index:200}.category-badge{display:inline-block;padding:2px 10px;border-radius:20px;font-size:.78rem;font-weight:600}.stats-bar{display:flex;align-items:center;background:#fff;border-radius:12px;padding:20px 32px;margin-bottom:24px;box-shadow:0 1px 4px #0000000f;gap:32px}.stat{display:flex;flex-direction:column;align-items:center;gap:4px}.stat-number{font-size:1.5rem;font-weight:800;color:#1a1a1a}.stat-label{font-size:.8rem;color:#6b7280;text-transform:uppercase;letter-spacing:.05em}.stat-divider{width:1px;height:40px;background:#e5e7eb}.secondary-actions{display:flex;gap:8px;justify-content:flex-end}.edit-btn{padding:6px 16px;background:#fff;color:#4a7cf6;border:1px solid #4a7cf6;border-radius:8px;cursor:pointer;font-size:.85rem}.edit-btn:hover{background:#4a7cf6;color:#fff}.leaderboard-table{background:#fff;border-radius:12px;overflow:hidden;box-shadow:0 1px 4px #0000000f}.table-header{display:grid;grid-template-columns:80px 1fr 120px;padding:16px 24px;font-weight:700;border-bottom:1px solid #e5e7eb}.table-row{display:grid;grid-template-columns:80px 1fr 120px;padding:20px 24px;border-bottom:1px solid #f3f4f6;align-items:center}.rank{display:inline-flex;align-items:center;justify-content:center;width:36px;height:36px;border-radius:8px;font-weight:700;background:#f3f4f6}.rank-1{background:#f59e0b;color:#fff}.rank-2{background:#9ca3af;color:#fff}.rank-3{background:#d97706;color:#fff}.leaderboard-header{margin-bottom:24px}.leaderboard-header h1{font-size:2rem;font-weight:800;margin-bottom:4px}.leaderboard-header p{color:#6b7280}.modal-overlay{position:fixed;top:0;right:0;bottom:0;left:0;background:#0006;display:flex;align-items:center;justify-content:center;z-index:100}.modal{background:#fff;border-radius:12px;padding:32px;width:100%;max-width:560px;margin:24px}.modal-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:24px}.modal-header h2{font-size:1.3rem;font-weight:700}.modal-header button{background:none;border:none;font-size:1rem;cursor:pointer;color:#6b7280}.modal-buttons{display:flex;gap:12px;margin-top:24px}.modal-buttons button:first-child{flex:1;padding:14px;background:#fff;border:2px solid #e5e7eb;border-radius:8px;font-size:1rem;cursor:pointer;font-weight:600}.modal-buttons button:last-child{flex:1;padding:14px;background:#4a7cf6;color:#fff;border:none;border-radius:8px;font-size:1rem;cursor:pointer}.error{color:#ef4444;font-size:.85rem;margin-bottom:12px}@media (max-width: 375px){.dashboard-header{flex-direction:column;gap:16px}.habit-card{flex-direction:column;align-items:flex-start;gap:12px}.complete-btn{width:100%}}#app{display:flex;flex-direction:column;min-height:100vh}
