/* Yleiset tyylit */
:root {
	--primary-color: #0d6efd;
	--primary-dark: #0a58ca;
	--secondary-color: #6c757d;
	--success-color: #198754;
	--danger-color: #dc3545;
	--warning-color: #ffc107;
	--info-color: #0dcaf0;
	--light-color: #f8f9fa;
	--dark-color: #212529;
}

body {
	font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
	color: #333;
	line-height: 1.6;
}

/* Parantaa sivun asemointia */
.container {
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 15px;
}

.cursor-pointer {
	cursor: pointer;
}

/* Navigaatio */
.navbar {
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
	padding: 0.8rem 1rem;
}

.navbar-brand {
	font-weight: 600;
	font-size: 1.4rem;
}

.nav-link {
	font-weight: 500;
	padding: 0.5rem 1rem;
	transition: all 0.2s;
}

.nav-link:hover {
	background-color: rgba(255, 255, 255, 0.1);
	border-radius: 4px;
}

/* Kortit */
.card {
	border: none;
	border-radius: 10px;
	overflow: hidden;
	transition: all 0.3s ease;
	margin-bottom: 1.5rem;
}

.card:hover {
	transform: translateY(-5px);
	box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.card-header {
	font-weight: 600;
	padding: 1rem 1.25rem;
}

/* Tehtäväkortit */
.task-card {
	height: 100%;
	display: flex;
	flex-direction: column;
}

.task-card .card-body {
	flex-grow: 1;
	display: flex;
	flex-direction: column;
}

.task-card .card-title {
	margin-bottom: 0.75rem;
	font-weight: 600;
}

.task-completed {
	opacity: 0.7;
	background-color: rgba(25, 135, 84, 0.05);
}

.priority-high {
	border-left: 5px solid var(--danger-color);
}

.priority-medium {
	border-left: 5px solid var(--warning-color);
}

.priority-low {
	border-left: 5px solid var(--success-color);
}

/* Badge ja status-indikaattorit */
.badge {
	font-weight: 500;
	padding: 0.35em 0.65em;
	border-radius: 50rem;
}

.category-badge {
	font-size: 0.75rem;
	padding: 0.25rem 0.5rem;
	border-radius: 50rem;
}

/* Lomakkeet */
.form-control {
	padding: 0.5rem 0.75rem;
	border-radius: 0.375rem;
	border: 1px solid #ced4da;
	transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control:focus {
	border-color: var(--primary-color);
	box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.input-group-text {
	background-color: #f8f9fa;
	border: 1px solid #ced4da;
}

/* Painikkeet */
.btn {
	padding: 0.5rem 1rem;
	border-radius: 0.375rem;
	font-weight: 500;
	transition: all 0.2s;
}

.btn-primary {
	background-color: var(--primary-color);
	border-color: var(--primary-color);
}

.btn-primary:hover {
	background-color: var(--primary-dark);
	border-color: var(--primary-dark);
}

.btn-outline-primary {
	color: var(--primary-color);
	border-color: var(--primary-color);
}

.btn-outline-primary:hover {
	background-color: var(--primary-color);
	color: white;
}

.btn-lg {
	padding: 0.75rem 1.5rem;
	font-size: 1.1rem;
}

/* Kirjautumis- ja rekisteröitymissivut */
.login-page {
	min-height: 100vh;
	display: flex;
	align-items: center;
	justify-content: center;
}

.auth-card {
	width: 100%;
	max-width: 450px;
	margin: 2rem auto;
}

.auth-card .card-header {
	text-align: center;
	padding: 1.5rem;
}

.auth-card .card-body {
	padding: 2rem;
}

/* Profiilisivu */
.profile-avatar {
	width: 100px;
	height: 100px;
	background-color: var(--primary-color);
	color: white;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 2.5rem;
	margin: 0 auto 1rem;
}

/* Tehtävänäkymä */
.task-detail .status-badge {
	font-size: 1rem;
	padding: 0.35rem 0.75rem;
}

.task-comments .comment {
	margin-bottom: 1.5rem;
}

.task-comments .comment-avatar {
	width: 45px;
	height: 45px;
	background-color: #e9ecef;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
}

.task-comments .comment-body {
	background-color: #f8f9fa;
	border-radius: 0.5rem;
	padding: 1rem;
}

/* Mobiililaitteiden optimointi */
@media (max-width: 767.98px) {
	.card-header h3 {
		font-size: 1.25rem;
	}

	.btn {
		padding: 0.4rem 0.8rem;
	}

	.form-control {
		padding: 0.4rem 0.7rem;
	}
}

/* Animaatiot */
.fade-in {
	animation: fadeIn ease 0.5s;
}

@keyframes fadeIn {
	0% {
		opacity: 0;
	}
	100% {
		opacity: 1;
	}
}

/* Taulukot */
.table > :not(:first-child) {
	border-top: 1px solid currentColor;
}

.table th {
	font-weight: 600;
	background-color: rgba(0, 0, 0, 0.03);
}

/* Päivämääräkenttien tyyli */
.flatpickr-calendar {
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
	border-radius: 8px;
}

/* Kategoriahallinta */
.color-box {
	display: inline-block;
	width: 24px;
	height: 24px;
	border-radius: 4px;
	border: 1px solid rgba(0, 0, 0, 0.1);
}

.icon-btn {
	padding: 0.5rem;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	height: 100%;
}

.icon-btn i {
	font-size: 1.25rem;
}

/* Toggle-painikkeet salasananäkymälle */
.toggle-password {
	cursor: pointer;
}

/* Käyttäjähallinta */
.user-icon {
	width: 40px;
	height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
}
