/* Reset básico */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

body {
	font-family: 'Segoe UI', Roboto, sans-serif;
	background-color: #f5f7fa;
	color: #333;
	line-height: 1.6;
}

/* Cabeçalho */
header {
	background: linear-gradient(135deg, #006400, #228b22);
	color: #fff;
	padding: 1rem;
	text-align: center;
	font-size: 1.5rem;
	font-weight: bold;
	letter-spacing: 1px;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

header div {
	display: inline-block;
}

/* Conteúdo principal */
main {
	/*display: flex;*/
	justify-content: center;
	gap: 1rem;
	padding: 1rem;
}

/* Blocos de seção */
main > div {
	background: #fff;
	border-radius: 8px;
	padding: 1rem;
	width: 100%;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

h4 {
	margin-bottom: 1rem;
	color: #006400;
	font-size: 1.2rem;
	border-bottom: 2px solid #228b22;
	padding-bottom: 0.5rem;
}

/* Lista */
ul {
	list-style: none;
}

li {
	margin-bottom: 0.8rem;
}

a {
	text-decoration: none;
	color: #333;
	font-weight: 500;
	/*display: flex;*/
	justify-content: space-between;
	align-items: center;
	padding: 0.6rem 0.8rem;
	border-radius: 6px;
	transition: background 0.3s, color 0.3s;
}

a:hover {
	background: #e6ffe6;
	color: #006400;
}

a span {
	font-size: 0.85rem;
	color: #555;
	font-style: italic;
}

/* Rodapé */
footer {
	background: #222;
	color: #ccc;
	text-align: center;
	padding: 1rem;
	margin-top: 2rem;
	font-size: 0.9rem;
}

footer p {
	margin: 0;
}

/* ====== NAV ====== */
nav {
	background: #e6ffe6;
	border-bottom: 2px solid #228b22;
	padding: 0.5rem 1rem;
	margin-bottom: 1.5rem;
}

nav ul {
	list-style: none;
}

nav li {
	display: inline-block;
	margin-right: 1rem;
}

nav a {
	text-decoration: none;
	color: #006400;
	font-weight: bold;
	padding: 0.4rem 0.8rem;
	border-radius: 4px;
	transition: background 0.3s;
}

nav a:hover {
	background: #cceccc;
}

/* ====== TÍTULOS ====== */
h1 {
	font-size: 1.6rem;
	margin: 0.5rem 0;
	color: #222;
}

h1 span {
	font-size: 1rem;
	color: #555;
	font-style: italic;
}

h2 {
	font-size: 1.3rem;
	margin: 1rem 0 0.5rem;
	color: #006400;
	border-left: 4px solid #228b22;
	padding-left: 0.5rem;
}

/* ====== TABELAS ====== */
/* ====== CONTAINER DE TABELAS ====== */
table {
	border-collapse: collapse;
	min-width: 600px; /* largura mínima para não ficar estreita */
	width: 100%;
	table-layout: auto; /* deixa o navegador calcular a largura das colunas */
	margin-bottom: 10px;
}

th,
td {
	border: 1px solid #ccc;
	padding: 0.6rem;
	text-align: center;
	white-space: nowrap; /* evita quebra estranha de nomes */
}

/* Cabeçalho */
th {
	background: #228b22;
	color: #fff;
}

/* Zebra striping */
tr:nth-child(even) {
	background: #f9f9f9;
}

tr:hover {
	background: #e6ffe6;
}

/* ====== WRAPPER PARA ROLAGEM ====== */
div > table {
	display: block; /* força o table a respeitar o wrapper */
	overflow-x: auto; /* ativa rolagem horizontal */
	max-width: 100%; /* não ultrapassa o container */
}

/* ====== AJUSTE PARA PROGRESS BAR NAS CELULAS ====== */
td .progress {
	min-width: 120px; /* garante espaço para barra */
	margin: 0 auto;
}

/* ====== PROGRESS BAR ====== */
.progress {
	background-color: #ddd;
	border-radius: 10px;
	overflow: hidden;
}

.progress-bar {
	text-align: center;
	color: #fff;
	font-weight: bold;
	line-height: 20px;
}

/* ====== CANVAS ====== */
canvas {
	border: 1px solid #ccc;
	margin: 1rem 0;
	background: #fff;
	display: block;
	padding: 0.5rem;
	border-radius: 6px;
}

/* ====== BLOCO DE SEÇÃO ====== */
main > div {
	margin-bottom: 2rem;
}

main > div > div:first-child {
	font-weight: bold;
	font-size: 1.1rem;
	margin-bottom: 0.5rem;
	color: #006400;
}

/* ====== FORMULÁRIOS ====== */
form {
	background: #fff;
	border: 1px solid #ccc;
	padding: 1.5rem;
	border-radius: 8px;
	margin: 1.5rem 0;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

/* Labels */
label {
	display: block;
	margin-bottom: 0.4rem;
	font-weight: bold;
	color: #006400;
}

/* Inputs de texto, email, senha */
input[type='text'],
input[type='email'],
input[type='password'],
input[type='number'],
select,
textarea {
	width: 100%;
	padding: 0.6rem;
	border: 1px solid #bbb;
	border-radius: 6px;
	font-size: 1rem;
	margin-bottom: 1rem;
	transition: border-color 0.3s, box-shadow 0.3s;
}

input:focus,
select:focus,
textarea:focus {
	border-color: #228b22;
	box-shadow: 0 0 5px rgba(34, 139, 34, 0.4);
	outline: none;
}

/* Radio e Checkbox */
input[type='radio'],
input[type='checkbox'] {
	margin-right: 0.5rem;
	accent-color: #228b22; /* cor moderna para radios/checkboxes */
}

.radio-group,
.checkbox-group {
	margin-bottom: 1rem;
}

/* Botões */
button,
input[type='submit'],
input[type='reset'] {
	background: #228b22;
	color: #fff;
	border: none;
	padding: 0.7rem 1.2rem;
	border-radius: 6px;
	font-size: 1rem;
	font-weight: bold;
	cursor: pointer;
	transition: background 0.3s, transform 0.2s;
}

button:hover,
input[type='submit']:hover,
input[type='reset']:hover {
	background: #006400;
	transform: scale(1.03);
}

button:disabled,
input[type='submit']:disabled {
	background: #ccc;
	cursor: not-allowed;
}

/* Textarea */
textarea {
	resize: vertical;
	min-height: 100px;
}

/* Mensagens de erro/validação */
input:invalid {
	border-color: #d9534f;
}

input:valid {
	border-color: #5cb85c;
}
