:root {
    --primary: #2980b9;
    --primary-hover: #2471a3;
    --success: #27ae60;
    --bg-color: #f4f7f6;
    --text-color: #333;
    --card-bg: #fff;
}
body { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; background-color: var(--bg-color); color: var(--text-color); margin: 0; padding: 0; display: flex; flex-direction: column; align-items: center; min-height: 100vh; }
.container { width: 100%; max-width: 600px; padding: 20px; box-sizing: border-box; flex: 1; }
.nav-bar { width: 100%; background: var(--card-bg); padding: 15px 20px; box-shadow: 0 2px 4px rgba(0,0,0,0.05); display: flex; justify-content: space-between; align-items: center; box-sizing: border-box; }
.nav-bar span { font-size: 0.9em; color: #7f8c8d; }
.nav-bar a { color: #e74c3c; text-decoration: none; font-weight: bold; }
h1 { text-align: center; color: #2c3e50; margin-bottom: 20px; }

/* Formularze (Logowanie/Rejestracja) */
.auth-form { background: var(--card-bg); padding: 30px; border-radius: 12px; box-shadow: 0 4px 6px rgba(0,0,0,0.05); margin-top: 50px; }
.auth-form input { width: 100%; padding: 12px; margin-bottom: 15px; border: 1px solid #ccc; border-radius: 8px; box-sizing: border-box; font-size: 1em; }
.auth-form button { width: 100%; background: var(--primary); color: white; border: none; padding: 15px; border-radius: 8px; font-size: 1.1em; font-weight: bold; cursor: pointer; }
.auth-form button:hover { background: var(--primary-hover); }
.auth-links { text-align: center; margin-top: 15px; }
.auth-links a { color: var(--primary); text-decoration: none; }
.error-msg { color: #e74c3c; text-align: center; margin-bottom: 15px; }

/* Skaner (index) */
.upload-wrapper { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 60vh; }
.upload-btn-wrapper { position: relative; overflow: hidden; display: inline-block; }
.btn-scan { border: none; color: white; background-color: var(--primary); padding: 20px 40px; border-radius: 12px; font-size: 1.5em; font-weight: bold; box-shadow: 0 4px 6px rgba(0,0,0,0.1); cursor: pointer; }
.upload-btn-wrapper input[type=file] { font-size: 100px; position: absolute; left: 0; top: 0; opacity: 0; height: 100%; cursor: pointer; }
.pending-info { margin-bottom: 30px; color: #e67e22; font-weight: bold; background: #fdebd0; padding: 10px 20px; border-radius: 8px; }
#loader { display: none; margin-top: 30px; border: 6px solid #f3f3f3; border-top: 6px solid var(--primary); border-radius: 50%; width: 50px; height: 50px; animation: spin 1s linear infinite; }
@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

/* Lista Zakupów */
.category { background: var(--card-bg); border-radius: 12px; padding: 15px 20px; margin-bottom: 20px; box-shadow: 0 4px 6px rgba(0,0,0,0.05); }
.category h2 { margin-top: 0; font-size: 1.2em; color: var(--primary); border-bottom: 2px solid #ecf0f1; padding-bottom: 10px; margin-bottom: 10px; }
ul { list-style-type: none; padding: 0; margin: 0; }
li { padding: 12px 5px; border-bottom: 1px solid #f0f0f0; cursor: pointer; display: flex; align-items: center; font-size: 1.1em; user-select: none; }
li:last-child { border-bottom: none; }
li::before { content: '⬜'; margin-right: 15px; font-size: 1.2em; transition: all 0.2s; }
li.completed { text-decoration: line-through; color: #a0aab5; }
li.completed::before { content: '✅'; opacity: 0.7; }
.finish-spacer { height: 80px; }
#finishBtn { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); background-color: var(--success); color: white; border: none; padding: 15px 40px; border-radius: 30px; font-size: 1.2em; font-weight: bold; box-shadow: 0 5px 15px rgba(39, 174, 96, 0.4); cursor: pointer; width: 90%; max-width: 400px; z-index: 1000; }
