* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

body {
	font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	min-height: 100vh;
	padding: 10px;
}

.container {
	max-width: 1200px;
	margin: 0 auto;
	background: white;
	border-radius: 20px;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
	overflow: hidden;
}

header {
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: white;
	padding: 20px 15px;
	text-align: center;
}

header h1 {
	font-size: 2.2em;
	margin-bottom: 5px;
	text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.subtitle {
	font-size: 1em;
	opacity: 0.9;
}

main {
	padding: 20px 15px;
}

.nav-buttons {
	margin-bottom: 20px;
}

.back-link {
	display: inline-block;
	padding: 8px 16px;
	background: #667eea;
	color: white;
	text-decoration: none;
	border-radius: 8px;
	transition: background 0.3s;
	font-size: 0.95em;
}

.back-link:hover {
	background: #764ba2;
}

.admin-section {
	margin-bottom: 30px;
	background: #f9f9f9;
	padding: 20px;
	border-radius: 12px;
}

.admin-section h2 {
	color: #333;
	margin-bottom: 15px;
	font-size: 1.5em;
}

.region-management {
    background: white;
    padding: 15px;
    border-radius: 8px;
}

.add-region-form {
    display: flex;
    gap: 8px;
    margin-bottom: 15px;
}

.add-region-form input {
    flex: 1;
    padding: 10px;
    font-size: 0.95em;
    border: 2px solid #ddd;
    border-radius: 8px;
    transition: border-color 0.3s;
}

.add-region-form input:focus {
    outline: none;
    border-color: #667eea;
}

.btn-add {
	padding: 10px 20px;
	background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
	color: white;
	border: none;
	border-radius: 8px;
	cursor: pointer;
	font-size: 0.95em;
	transition: transform 0.2s, box-shadow 0.2s;
}

.btn-add:hover {
	transform: translateY(-2px);
	box-shadow: 0 5px 15px rgba(76, 175, 80, 0.4);
}

.regions-list {
    display: grid;
    gap: 8px;
}

.region-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: #f5f5f5;
    border-radius: 8px;
    transition: background 0.3s;
}

.region-item:hover {
    background: #e8e8e8;
}

.region-name {
    font-size: 1em;
    color: #333;
    font-weight: 500;
}

.region-actions {
    display: flex;
    gap: 8px;
}

.total-display {
	text-align: center;
	font-size: 1.3em;
	margin-bottom: 15px;
	color: #333;
	font-weight: bold;
}

.total-display span {
	color: #667eea;
	font-size: 1.2em;
}

.table-container {
	overflow-x: auto;
}

table {
	width: 100%;
	border-collapse: collapse;
	background: white;
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

thead {
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: white;
}

th {
	padding: 12px;
	text-align: left;
	font-weight: bold;
	font-size: 0.95em;
}

td {
	padding: 10px 12px;
	border-bottom: 1px solid #e0e0e0;
	font-size: 0.95em;
}

tbody tr:hover {
	background: #f5f5f5;
}

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

.action-buttons {
	display: flex;
	gap: 8px;
}

.btn-edit,
.btn-delete {
	padding: 5px 10px;
	border: none;
	border-radius: 5px;
	cursor: pointer;
	font-size: 0.85em;
	transition: transform 0.2s, box-shadow 0.2s;
}

.btn-edit {
	background: #2196F3;
	color: white;
}

.btn-edit:hover {
	background: #1976D2;
	transform: translateY(-2px);
	box-shadow: 0 3px 10px rgba(33, 150, 243, 0.3);
}

.btn-delete {
	background: #f44336;
	color: white;
}

.btn-delete:hover {
	background: #d32f2f;
	transform: translateY(-2px);
	box-shadow: 0 3px 10px rgba(244, 67, 54, 0.3);
}

/* Modal */
.modal {
	display: none;
	position: fixed;
	z-index: 1000;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
	background-color: rgba(0, 0, 0, 0.5);
	animation: fadeIn 0.3s;
}

@keyframes fadeIn {
	from {
		opacity: 0;
	}

	to {
		opacity: 1;
	}
}

.modal-content {
	background-color: white;
	margin: 10% auto;
	padding: 25px;
	border-radius: 12px;
	width: 90%;
	max-width: 450px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
	animation: slideIn 0.3s;
}

@keyframes slideIn {
	from {
		transform: translateY(-50px);
		opacity: 0;
	}

	to {
		transform: translateY(0);
		opacity: 1;
	}
}

.close {
	color: #aaa;
	float: right;
	font-size: 28px;
	font-weight: bold;
	cursor: pointer;
	transition: color 0.3s;
}

.close:hover {
	color: #000;
}

.modal-content h2 {
	margin-bottom: 15px;
	color: #333;
	font-size: 1.5em;
}

.form-group {
	margin-bottom: 15px;
}

.form-group label {
	display: block;
	margin-bottom: 6px;
	color: #333;
	font-weight: bold;
	font-size: 0.95em;
}

.form-group input {
	width: 100%;
	padding: 10px;
	font-size: 0.95em;
	border: 2px solid #ddd;
	border-radius: 8px;
	transition: border-color 0.3s;
}

.form-group select {
	width: 100%;
	padding: 10px;
	font-size: 0.95em;
	border: 2px solid #ddd;
	border-radius: 8px;
	transition: border-color 0.3s;
	background: white;
	cursor: pointer;
}

.form-group input:focus,
.form-group select:focus {
	outline: none;
	border-color: #667eea;
}

.form-buttons {
	display: flex;
	gap: 8px;
	justify-content: flex-end;
}

.btn-save,
.btn-cancel {
	padding: 10px 20px;
	border: none;
	border-radius: 8px;
	font-size: 0.95em;
	cursor: pointer;
	transition: transform 0.2s, box-shadow 0.2s;
}

.btn-save {
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: white;
}

.btn-save:hover {
	transform: translateY(-2px);
	box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-cancel {
	background: #e0e0e0;
	color: #333;
}

.btn-cancel:hover {
	background: #d0d0d0;
}

/* Login Screen */
.login-screen {
	display: flex;
	justify-content: center;
	align-items: center;
	min-height: 100vh;
	padding: 20px;
}

.login-container {
	background: white;
	padding: 40px;
	border-radius: 15px;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
	max-width: 400px;
	width: 100%;
	text-align: center;
}

.login-container h1 {
	color: #667eea;
	margin-bottom: 30px;
	font-size: 2em;
}

.login-form-group {
	margin-bottom: 20px;
	text-align: left;
}

.login-form-group label {
	display: block;
	margin-bottom: 8px;
	color: #333;
	font-weight: bold;
}

.login-form-group input {
	width: 100%;
	padding: 12px;
	font-size: 1em;
	border: 2px solid #ddd;
	border-radius: 8px;
	transition: border-color 0.3s;
	box-sizing: border-box;
}

.login-form-group input:focus {
	outline: none;
	border-color: #667eea;
}

.btn-login {
	width: 100%;
	padding: 12px;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: white;
	border: none;
	border-radius: 8px;
	font-size: 1.1em;
	font-weight: bold;
	cursor: pointer;
	transition: transform 0.2s, box-shadow 0.2s;
	margin-bottom: 15px;
}

.btn-login:hover {
	transform: translateY(-2px);
	box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.login-error {
	color: #f44336;
	margin-top: 10px;
	font-size: 0.9em;
	min-height: 20px;
}

.back-link-login {
	display: inline-block;
	margin-top: 15px;
	color: #667eea;
	text-decoration: none;
	font-size: 0.95em;
}

.back-link-login:hover {
	color: #764ba2;
}

.logout-btn {
	display: inline-block;
	padding: 8px 16px;
	background: #f44336;
	color: white;
	border: none;
	border-radius: 8px;
	cursor: pointer;
	font-size: 0.95em;
	margin-left: 10px;
	transition: background 0.3s;
}

.logout-btn:hover {
	background: #d32f2f;
}