/* ==============================
   LeishCalc - Style
   ============================== */
/* Reset básico */
* {
    box-sizing: border-box;
}
html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
    min-height: 100%;
    font-family: Arial, Helvetica, sans-serif;
    color: #333;
    background-image: url("pattern.jpg");
	background-repeat: no-repeat;
    background-position: center center;
    background-size: cover;
    background-attachment: fixed;
}
/* ==============================
   Header
   ============================== */
header {
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px;
    background: #1976d2;
    color: white;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}
.header-content {
    display: flex;
    align-items: center;
}
.logo img {
    width: 55px;
    height: 55px;
    object-fit: contain;
    margin-right: 15px;
}
.header-text {
    display: flex;
    flex-direction: column;
}
.tagline {
    font-size: 26px;
    font-weight: bold;
}
.subtagline {
    font-size: 14px;
    opacity: 0.9;
}
/* ==============================
   Botão Hambúrguer
   ============================== */
.hamburger-btn {
    width: 45px;
    height: 45px;
    border: none;
    background: transparent;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
}
.bar {
    height: 3px;
    width: 28px;
    background: white;
    border-radius: 3px;
}
/* ==============================
   Overlay
   ============================== */
.hamburger-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 1100;
    display: none;
}
.hamburger-overlay.active {
    display: block;
}
/* ==============================
   Menu lateral
   ============================== */
.hamburger-menu {
    position: fixed;
    top: 0;
    left: -300px;
    width: 280px;
    height: 100vh;
    background: white;
    z-index: 1200;
    box-shadow:
        3px 0 10px rgba(0,0,0,0.25);
    transition:
        left 0.3s ease;
	overflow-y: auto;
    max-height: calc(100vh - 70px);
}
.hamburger-menu.active {
    left: 0;
}
.hamburger-menu-header {
    height: 70px;
    background: #1976d2;
    color:white;
    display:flex;
    align-items:center;
    justify-content:space-between;
    padding:0 20px;
}
.hamburger-menu-header h3 {
    margin:0;
}
.hamburger-close-btn {
    background:none;
    border:none;
    color:white;
    font-size:32px;
    cursor:pointer;
}
/* Navegação */
.hamburger-nav {
    display:flex;
    flex-direction:column;
    padding:15px;
}
.hamburger-nav-btn {
    border:none;
    background:white;
    text-align:left;
    padding:15px;
    margin-bottom:8px;
    border-radius:8px;
    font-size:16px;
    cursor:pointer;
    transition:background 0.2s;
}
.hamburger-nav-btn:hover {
    background:#e3f2fd;
}
.hamburger-nav-btn.active {
    background:#1976d2;
    color:white;
}
/* ==============================
   Conteúdo
   ============================== */
.main-content {
	padding-top:100px;
	padding-left:15px;
	padding-right:15px;
	width:100%;
	max-width:900px;
	margin:auto;
	overflow-x:hidden;
}
.tab-content {
    display:none;
}
.tab-content.active {
    display:block;
}
h2 {
    color:#1976d2;
    font-size:22px;
}
.box {
	background: rgba(255,255,255,0.95);
	border-radius:12px;
	padding:20px;
	margin-bottom:20px;
	box-shadow:0 2px 8px rgba(0,0,0,0.12);
	width:100%;
	min-width:0;
}

.table-container {
	width: 100%;
	overflow-x: auto;
}

.data-table {
	width: max-content;
	min-width: 100%;
	border-collapse: collapse;
	margin-top: 15px;
}

.data-table th,
.data-table td {
	padding: 10px;
	text-align: left;
	border-bottom: 1px solid #ddd;
	white-space: normal;
	word-break: break-word;
	overflow-wrap: anywhere;
}
/* ==============================
   Footer
   ============================== */
footer {
    margin-top: 30px;
    padding: 20px;
    text-align: center;
    color: rgba(255,255,255,0.85);
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
    background: transparent;
}
/* ==============================
   Responsividade
   ============================== */
@media(max-width:600px) {
header {
    width: 100%;
}
.header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}
.header-content {
    display: flex;
    align-items: center;
}
#session-bar {
    display: block;
    width: 100%;
    clear: both;
}
    .logo img {
        width:45px;
        height:45px;
    }
    .tagline {
        font-size:22px;
    }
    .subtagline {
        font-size:12px;
    }
    .main-content {
        padding-top:90px;
    }
}
.session-bar {
    margin-top:80px;
    padding:8px 15px;
    background:white;
    display:flex;
    justify-content:space-around;
    flex-wrap:wrap;
    gap:10px;
    box-shadow:
        0 2px 5px rgba(0,0,0,0.1);
    font-size:14px;
}
.session-item {
    display:flex;
    gap:5px;
}
.session-label {
    font-weight:bold;
    color:#1976d2;
}
@media(max-width:600px) {
.session-bar {
    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(3px);
}
}
.message {
    margin-top: 20px;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
}
.message.error {
    background: #fdeaea;
    color: #a30000;
    border: 1px solid #f0b5b5;
}
.message.success {
    background: #e9f9ec;
    color: #006b2d;
    border: 1px solid #9fd5ac;
}
/* ==========================
   Formulários
   ========================== */
.form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 18px;
}
.form-group label {
    margin-bottom: 6px;
    font-weight: 600;
    color: #333;
}
.form-group input,
.form-group select,
.form-group textarea {
    padding: 12px;
    border: 1px solid #c8c8c8;
    border-radius: 8px;
    font-size: 15px;
    box-sizing: border-box;
    width: 100%;
    transition: border-color .2s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #1976d2;
    box-shadow: 0 0 4px rgba(25,118,210,.3);
}
/* ==========================
   Botões
   ========================== */
.primary-btn {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 8px;
    background: #1976d2;
    color: white;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: background .2s;
}
.primary-btn:hover {
    background: #125ca8;
}
.primary-btn:active {
    transform: scale(.98);
}
.main-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    max-width: 1400px;
    padding: 20px;
    box-sizing: border-box;
}
.box {
    width: 100%;
    box-sizing: border-box;
}
.form-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}
.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.form-group label {
    font-weight: bold;
    color: #444;
    font-size: 14px;
}
.form-group input,
.form-group select {
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 15px;
    width: 100%;
    box-sizing: border-box;
}
.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #0066cc;
}
.form-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 15px;
}

@media (max-width: 600px) {
	.form-actions button {
		width: 100%;
	}
}
.primary-btn,
.secondary-btn {
	width: 220px;
	padding: 12px 20px;
	border: none;
	border-radius: 8px;
	color: white;
	font-size: 15px;
	cursor: pointer;
	text-align: center;
	box-sizing: border-box;
}

.primary-btn {
	background: #3182ce;
}

.secondary-btn {
	background: #64748b;
}
.primary-btn:hover {
    background: #004c99;
}
.secondary-btn:hover {
    background: #004c99;
}
.action-btn {
	background: #28a745;
	color: white;
	padding: 12px 20px;
	border: none;
	border-radius: 8px;
	font-size: 15px;
	cursor: pointer;
	transition: background 0.2s ease;
}

.action-btn:hover {
	background: #218838;
}

.action-btn:active {
	background: #1e7e34;
}
#tutores-lista tr {
    cursor:pointer;
}
#tutores-lista tr:hover {
    background:#eeeeee;
}
#tutores-lista tr.selected {
    background:#cce5ff;
}
/* ============================================================
   ESTADIAMENTO
============================================================ */

.form-section {
	margin-top: 24px;
	padding-top: 20px;
	border-top: 1px solid #e5e7eb;
	overflow-x:auto;
	min-width:0;
}

.form-section:first-child {
	margin-top: 0;
	padding-top: 0;
	border-top: none;
}

.form-section h3 {
	margin-bottom: 12px;
	color: #1e3a8a;
	font-size: 1.15rem;
}

.form-help {
	margin-bottom: 16px;
	color: #6b7280;
	font-size: 0.95rem;
	line-height: 1.5;
}

.checkbox-group {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.checkbox-label {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	padding: 12px;
	border: 1px solid #d1d5db;
	border-radius: 8px;
	background: #ffffff;
	cursor: pointer;
	transition: all 0.2s;
}

.checkbox-label:hover {
	background: #f8fafc;
	border-color: #3b82f6;
}

.checkbox-label input[type="checkbox"] {
	margin-top: 3px;
	transform: scale(1.15);
	cursor: pointer;
}

.checkbox-label span {
	line-height: 1.45;
	flex: 1;
}

.resultado-card {
	margin-top: 20px;
	padding: 20px;
	border: 2px solid #2563eb;
	border-radius: 10px;
	background: #eff6ff;
}

.resultado-card h3 {
	margin: 0 0 12px 0;
	color: #1e40af;
}

#estagio-texto {
	margin: 0;
	font-size: 1.6rem;
	font-weight: bold;
	color: #1e3a8a;
	text-align: center;
}

#recomendacoes-texto {
	line-height: 1.6;
	white-space: pre-wrap;
}

#btn-calcular-estagio {
	min-width: 180px;
}

#btn-limpar-estadiamento {
	min-width: 120px;
}

#btn-salvar-resultado {
	min-width: 180px;
}
.checkbox-group {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
	gap: 10px;
}
.tabela-clinica-container {
	margin-top: 30px;
	background: #ffffff;
	border: 1px solid #dbe3ea;
	border-radius: 10px;
	padding: 20px;
	box-shadow: 0 2px 6px rgba(0,0,0,0.08);
	overflow-x: auto;
}

.tabela-clinica-container h3 {
	margin: 0 0 15px 0;
	color: #1e3a8a;
	font-size: 1.2rem;
}

.tabela-clinica {
	width: 100%;
	border-collapse: collapse;
	font-size: 14px;
}

.tabela-clinica th {
	background: #1e3a8a;
	color: white;
	padding: 10px;
	text-align: left;
	border-bottom: 2px solid #16306d;
}

.tabela-clinica td {
	padding: 10px;
	border-bottom: 1px solid #e5e7eb;
	vertical-align: top;
}

.tabela-clinica tr:nth-child(even) {
	background: #f8fafc;
}

.tabela-clinica tr:hover {
	background: #e8f1ff;
}

.tabela-clinica td:first-child {
	font-weight: bold;
	white-space: nowrap;
}

@media (max-width: 768px) {
	.tabela-clinica {
		font-size: 13px;
	}

	.tabela-clinica th,
	.tabela-clinica td {
		padding: 8px;
	}
}
.diretrizes-acoes {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 15px;
	margin-bottom: 15px;
}

.diretrizes-acoes button {
	max-width: 100%;
	box-sizing: border-box;
}
/* ======================================================
   RECEITA COM ESTADIAMENTO
====================================================== */

.receita-descricao {
    color: #555;
    font-size: 14px;
    margin-bottom: 20px;
}

#receita-est-paciente-info {
    background: #f8fafc;
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 20px;
    border: 1px solid #e2e8f0;
    font-size: 14px;
    line-height: 1.8;
}

.receita-paciente {
    color: #2d3748;
}


/* ======================================================
   BLOCOS DE MEDICAMENTOS
====================================================== */

.receita-medicamento {
    background: #ffffff;
    border: 1px solid #dbe5ef;
    border-radius: 10px;
    padding: 18px;
    margin-bottom: 20px;
}

.receita-medicamento h3 {
    margin: 0 0 15px 0;
    color: #2c5282;
    font-size: 16px;
}


/* ======================================================
   RADIO OPTIONS
====================================================== */

.receita-opcao {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 12px;
    margin-top: 10px;
    background: #f7fafc;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    font-size: 14px;
}

.receita-opcao:hover {
    background: #edf2f7;
}

.receita-opcao input[type="radio"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}


/* ======================================================
   DETALHES DO MEDICAMENTO
====================================================== */

.receita-detalhes {
    margin: 8px 0 15px 0px;
    padding: 12px 15px;
    background: #f8fafc;
    border-left: 4px solid #3182ce;
    border-radius: 6px;
    font-size: 13px;
    color: #4a5568;
    line-height: 1.6;
	overflow-x: auto;
}
.receita-detalhes select {
	width: max-content;
	min-width: 100%;
	box-sizing: border-box;
}

.receita-detalhes strong {
    color: #2d3748;
}


/* ======================================================
   COLEIRA
====================================================== */

.receita-bloco {
    margin-top: 18px;
    margin-bottom: 18px;
}

.receita-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    background: #f0fff4;
    border: 1px solid #9ae6b4;
    border-radius: 8px;
    color: #276749;
    font-weight: 600;
    cursor: pointer;
}

.receita-checkbox input {
    width: 18px;
    height: 18px;
}


/* ======================================================
   VETERINÁRIO
====================================================== */

#receita-est-veterinario {
    margin-top: 20px;
}

.receita-veterinario {
    background: #ebf8ff;
    border-left: 4px solid #3182ce;
    border-radius: 8px;
    padding: 15px;
    color: #2c5282;
    font-size: 14px;
}


/* ======================================================
   OBSERVAÇÕES
====================================================== */

.receita-bloco label {
    display: block;
    font-weight: 600;
    font-size: 13px;
    margin-bottom: 8px;
    color: #4a5568;
}

.receita-bloco textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #cbd5e0;
    border-radius: 8px;
    font-family: inherit;
    font-size: 14px;
    resize: vertical;
    box-sizing: border-box;
}

.receita-bloco textarea:focus {
    outline: none;
    border-color: #3182ce;
}


/* ======================================================
   BOTÕES
====================================================== */

.modal-botoes {
    display: flex;
    gap: 12px;
    margin-top: 25px;
}

.modal-botoes button {
    flex: 1;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    background: #007bff;
    color: white;
}

.modal-botoes button:hover {
    opacity: 0.9;
}

.modal-botoes button:last-child {
    background: #6c757d;
}

.prontuario-nota {
	margin: 6px 4px 12px 4px;
	padding: 8px 10px;
	background: #f4f8fc;
	border-left: 4px solid #3182ce;
	border-radius: 6px;
}
.prontuario-nota-cabecalho {
	display: flex;
	align-items: center;
	gap: 6px;
	margin: 0 0 5px 0;
	min-width: 0;
}
.prontuario-nota-titulo {
	margin: 0;
	padding: 0;
	line-height: 1;
	flex: 0 0 auto;
}
.prontuario-nota-data {
	font-size: 0.75em;
	font-weight: normal;
	color: #888;
	white-space: nowrap;
	flex: 0 0 auto;
}
.prontuario-nota-acoes {
	display: flex;
	flex-wrap: nowrap;
	gap: 4px;
	margin-left: auto;
	white-space: nowrap;
	flex: 0 0 auto;
}
.prontuario-nota-btn {
	flex: 0 0 auto;
	width: auto;
	padding: 2px 6px;
	font-size: 0.7em;
	line-height: 1.2;
	white-space: nowrap;
}
.prontuario-nota-texto {
	display: block;
	width: 100%;
	box-sizing: border-box;
	margin: 0;
	padding: 6px 8px;
	border: none;
	outline: none;
	background: transparent;
	resize: vertical;
	overflow: hidden;
	font-family: inherit;
	font-size: inherit;
}
.prontuario-nota-texto:focus {
	outline: none;
}
.prontuario-nota-arquivo {
	margin: 4px 0;
	font-size: 0.8em;
}
.prontuario-nota-texto-especial {
	background: #eef2f7;
	color: #475569;
}
@media (max-width: 600px) {
	.prontuario-nota {
		margin: 4px 2px 8px 2px;
		padding: 6px 7px;
		border-left-width: 3px;
	}
	.prontuario-nota-cabecalho {
		gap: 4px;
		margin-bottom: 3px;
	}
	.prontuario-nota-data {
		font-size: 0.7em;
	}
	.prontuario-nota-acoes {
		gap: 3px;
	}
	.prontuario-nota-btn {
		padding: 2px 5px;
		font-size: 0.65em;
	}
	.prontuario-nota-texto {
		padding: 5px 6px;
	}
	.prontuario-nota-arquivo {
		margin: 3px 0;
		font-size: 0.75em;
	}
}
.receita-bloco input[type="text"],
.receita-bloco input[type="number"] {
    width: 100%;
    max-width: 120px;
    box-sizing: border-box;
    padding: 10px 12px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    background: white;
    color: #334155;
}

.receita-bloco input[type="text"]:focus,
.receita-bloco input[type="number"]:focus {
    outline: none;
    border-color: #3182ce;
    box-shadow: 0 0 0 2px rgba(49, 130, 206, 0.15);
}

.receita-bloco input[type="checkbox"] {
    width: auto;
    max-width: none;
    padding: 0;
    margin: 0;
    border: none;
    box-shadow: none;
    accent-color: #3182ce;
}

.receita-bloco select {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    min-width: 0;
}
