/* Mesato — Área de cliente (mst-acct). Namespaced, marca via CSS vars, mobile-first. */

.mst-acct {
	--mst-acct-brand: var(--mst-brand, #b0703e);
	max-width: 760px;
	margin: 0 auto;
	padding: 0 16px;
	box-sizing: border-box;
	/* Empurra o footer para o fundo em páginas curtas (mesmo padrão das agendas). */
	min-height: 58vh;
	font-family: var(--mst-font-body, inherit);
}

.mst-acct-card,
.mst-acct-panel {
	background: rgba(255, 255, 255, 0.78);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	border: 1px solid rgba(0, 0, 0, 0.06);
	border-radius: 18px;
	padding: 32px;
	box-shadow: 0 12px 34px rgba(0, 0, 0, 0.07);
}

.mst-acct-tabs {
	display: flex;
	gap: 6px;
	margin-bottom: 22px;
	border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.mst-acct-tabs a {
	padding: 10px 14px;
	text-decoration: none;
	color: #6b6b6b;
	font-weight: 600;
	border-bottom: 2px solid transparent;
	margin-bottom: -1px;
}

.mst-acct-tabs a.is-on {
	color: var(--mst-acct-brand);
	border-bottom-color: var(--mst-acct-brand);
}

/* Subtítulos das secções do formulário. */
.mst-acct-sub {
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--mst-acct-brand);
	margin: 6px 0 2px;
}

.mst-acct-sub + .mst-acct-field,
.mst-acct-sub + .mst-acct-row2 {
	margin-top: 2px;
}

.mst-acct-form {
	display: flex;
	flex-direction: column;
	gap: 18px;
}

.mst-acct-field {
	display: flex;
	flex-direction: column;
	gap: 7px;
}

.mst-acct-field span {
	font-weight: 600;
	font-size: 15px;
	color: #3a3a3a;
}

.mst-acct-field input {
	width: 100%;
	padding: 16px 18px;
	min-height: 54px;
	border: 1px solid rgba(0, 0, 0, 0.22);
	border-radius: 12px;
	/* 16px evita o zoom automático dos campos no iOS. */
	font-size: 16px;
	line-height: 1.3;
	box-sizing: border-box;
	background: #fff;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.mst-acct-field input:focus {
	outline: none;
	border-color: var(--mst-acct-brand);
	/* Anel de foco derivado da cor da marca (conformidade com as Definições). */
	box-shadow: 0 0 0 3px color-mix( in srgb, var(--mst-acct-brand) 24%, transparent );
}

.mst-acct-row2 {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 18px;
}

.mst-acct-btn {
	margin-top: 6px;
	padding: 15px 20px;
	border: 0;
	border-radius: 999px;
	background: var(--mst-acct-brand);
	color: #fff;
	font-weight: 700;
	font-size: 16px;
	cursor: pointer;
	transition: filter 0.15s ease;
}

.mst-acct-btn:hover {
	filter: brightness(0.94);
}

.mst-acct-forgot {
	font-size: 13px;
	color: #6b6b6b;
	text-decoration: none;
	text-align: center;
}

/* Login social: divisor "ou" + botões dos fornecedores. */
.mst-acct-or {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 18px 0 4px;
	color: #8a8278;
	font-size: 13px;
}
.mst-acct-or::before,
.mst-acct-or::after {
	content: "";
	flex: 1;
	height: 1px;
	background: rgba(120, 100, 80, 0.18);
}
.mst-acct-social {
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.mst-acct-social-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	padding: 13px 18px;
	border: 1px solid rgba(60, 40, 25, 0.16);
	border-radius: 999px;
	background: #fff;
	color: #241f1a;
	font-weight: 600;
	font-size: 15px;
	text-decoration: none;
	transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
}
.mst-acct-social-btn:hover {
	background: #faf7f3;
	border-color: rgba(60, 40, 25, 0.3);
}
.mst-acct-social-btn:active {
	transform: translateY(1px);
}
.mst-acct-social-btn svg {
	flex: none;
}

.mst-acct-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	flex-wrap: wrap;
	margin-bottom: 18px;
}

.mst-acct-hi {
	font-size: 13px;
	color: #6b6b6b;
}

.mst-acct-name {
	font-size: 22px;
	font-weight: 700;
	color: #2a2a2a;
}

.mst-acct-logout {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 14px;
	color: var(--mst-acct-brand);
	text-decoration: none;
	font-weight: 700;
	padding: 8px 16px;
	border: 1px solid var(--mst-acct-brand);
	border-radius: 999px;
	transition: background 0.15s ease, color 0.15s ease;
}

.mst-acct-logout::before {
	content: "\21AA";
	font-size: 15px;
	line-height: 1;
}

.mst-acct-logout:hover {
	background: var(--mst-acct-brand);
	color: #fff;
}

.mst-acct-nav {
	display: flex;
	gap: 8px;
	margin-bottom: 18px;
	flex-wrap: wrap;
}

.mst-acct-navlink {
	padding: 9px 16px;
	border-radius: 999px;
	background: rgba(0, 0, 0, 0.04);
	color: #444;
	text-decoration: none;
	font-weight: 600;
	font-size: 14px;
}

.mst-acct-navlink.is-on {
	background: var(--mst-acct-brand);
	color: #fff;
}

.mst-acct-cards {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
	gap: 16px;
}

.mst-acct-tile {
	display: flex;
	flex-direction: column;
	gap: 5px;
	padding: 20px;
	border-radius: 14px;
	border: 1px solid rgba(0, 0, 0, 0.08);
	background: #fff;
	text-decoration: none;
	transition: transform 0.15s ease, box-shadow 0.15s ease;
}

a.mst-acct-tile:hover {
	transform: translateY(-2px);
	box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.mst-acct-tile.is-soon {
	opacity: 0.5;
}

.mst-acct-tile-t {
	font-weight: 700;
	color: #2a2a2a;
}

.mst-acct-tile-s {
	font-size: 13px;
	color: #6b6b6b;
}

.mst-acct-notice {
	padding: 13px 16px;
	border-radius: 12px;
	margin-bottom: 18px;
	font-weight: 600;
}

.mst-acct-notice.is-ok {
	background: #e6f4ea;
	color: #1a7f37;
}

.mst-acct-notice.is-err {
	background: #fce8e8;
	color: #b32d2e;
}

/* ---- Registos (encomendas / reservas) ---- */
.mst-acct-empty {
	padding: 28px;
	text-align: center;
	color: #6b6b6b;
	font-size: 15px;
}

.mst-acct-rec {
	border: 1px solid rgba(0, 0, 0, 0.08);
	border-radius: 14px;
	padding: 16px 18px;
	margin-bottom: 14px;
	background: #fff;
}

.mst-acct-rec-top {
	display: flex;
	align-items: center;
	gap: 12px;
	flex-wrap: wrap;
}

.mst-acct-rec-id {
	font-weight: 700;
	color: #2a2a2a;
}

.mst-acct-rec-when {
	color: #6b6b6b;
	font-size: 14px;
}

.mst-acct-badge {
	margin-left: auto;
	padding: 3px 12px;
	border-radius: 999px;
	background: color-mix( in srgb, var(--mst-acct-brand) 14%, transparent );
	color: var(--mst-acct-brand);
	font-size: 12px;
	font-weight: 700;
}

.mst-acct-rec-items {
	color: #444;
	font-size: 14px;
	margin-top: 8px;
}

.mst-acct-rec-total {
	margin-top: 8px;
	font-weight: 700;
	color: #2a2a2a;
}

.mst-acct-rec-cancel {
	margin-top: 12px;
}

.mst-acct-cancel-btn {
	padding: 8px 16px;
	border: 1px solid #d9534f;
	background: #fff;
	color: #b32d2e;
	border-radius: 999px;
	font-weight: 600;
	font-size: 14px;
	cursor: pointer;
}

.mst-acct-cancel-btn:hover {
	background: #b32d2e;
	color: #fff;
}

.mst-acct-rec-reorder {
	margin-top: 12px;
}

.mst-acct-reorder-btn {
	padding: 9px 18px;
	border: 1px solid var(--mst-acct-brand);
	background: #fff;
	color: var(--mst-acct-brand);
	border-radius: 999px;
	font-weight: 700;
	font-size: 14px;
	cursor: pointer;
	transition: background 0.15s ease, color 0.15s ease;
}

.mst-acct-reorder-btn:hover {
	background: var(--mst-acct-brand);
	color: #fff;
}

/* ---- Mobile (onde a maioria dos clientes vai estar) ---- */
@media (max-width: 600px) {
	.mst-acct {
		padding: 0 12px;
	}

	.mst-acct-card,
	.mst-acct-panel {
		padding: 20px;
		border-radius: 16px;
	}

	.mst-acct-head {
		flex-direction: column;
		align-items: flex-start;
		gap: 6px;
	}

	.mst-acct-name {
		font-size: 20px;
	}

	.mst-acct-row2 {
		grid-template-columns: 1fr;
	}

	.mst-acct-nav {
		gap: 6px;
	}
}

/* ---- Erro inline junto ao campo (UX, sobretudo mobile) ---- */
.mst-acct-fielderr {
	margin: -8px 0 14px;
	padding: 9px 12px;
	background: #fcf4f2;
	border: 1px solid #e3b9b3;
	border-left: 3px solid #b3261e;
	border-radius: 10px;
	color: #b3261e;
	font-size: 13.5px;
	line-height: 1.4;
}

/* ---- Consentimento RGPD no registo (Privacidade + Termos) ---- */
.mst-acct-consent {
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin: 4px 0 16px;
}
.mst-acct-check {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	font-size: 13.5px;
	line-height: 1.45;
	color: #5c5147;
	cursor: pointer;
}
.mst-acct-check input[type="checkbox"] {
	flex: 0 0 auto;
	width: 18px;
	height: 18px;
	margin-top: 1px;
	accent-color: var(--mst-acct-brand);
	cursor: pointer;
}
.mst-acct-check a {
	color: var(--mst-acct-brand);
	text-decoration: underline;
	text-underline-offset: 2px;
}
.mst-acct-check a:hover { text-decoration: none; }

/* ---- Privacidade (RGPD self-service) ---- */
.mst-acct-sec-title {
	margin: 0 0 4px;
	font-family: 'Cormorant Garamond', Georgia, serif;
	font-size: 26px;
	color: #2c2420;
}
.mst-acct-priv .mst-acct-sub { margin: 0 0 18px; color: #6b5f54; font-size: 15px; }
.mst-priv-card {
	background: var(--mst-glass, rgba(255, 255, 255, .72));
	border: 1px solid var(--mst-line, #e7ddcf);
	border-radius: 16px;
	padding: 20px 22px;
	margin-bottom: 16px;
}
.mst-priv-h { margin: 0 0 6px; font-size: 16px; font-weight: 700; color: #2c2420; }
.mst-priv-p { margin: 0 0 14px; font-size: 14.5px; color: #6b5f54; line-height: 1.55; }
.mst-priv-link {
	display: inline-block;
	color: var(--mst-acct-brand);
	font-weight: 600;
	text-decoration: underline;
}
.mst-priv-toggle {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-bottom: 14px;
	font-size: 14.5px;
	color: #2c2420;
	cursor: pointer;
}
.mst-priv-toggle input { width: 20px; height: 20px; accent-color: var(--mst-acct-brand); }
.mst-priv-field { margin: 0 0 12px; }
.mst-priv-field label { display: block; font-weight: 600; font-size: 13.5px; margin-bottom: 6px; color: #2c2420; }
.mst-priv-field input {
	width: 100%;
	box-sizing: border-box;
	padding: 13px 14px;
	min-height: 50px;
	border: 1px solid var(--mst-line, #e7ddcf);
	border-radius: 12px;
	font-size: 16px;
	background: #fff;
}
.mst-priv-field input:focus {
	outline: none;
	border-color: var(--mst-acct-brand);
	box-shadow: 0 0 0 3px color-mix( in srgb, var(--mst-acct-brand) 22%, transparent );
}
/* Botões da secção */
.mst-acct-priv .mst-acct-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: var(--mst-acct-brand);
	color: #fff;
	border: 1px solid var(--mst-acct-brand);
	border-radius: 12px;
	padding: 12px 22px;
	font-weight: 700;
	font-size: 14.5px;
	cursor: pointer;
	transition: filter .15s ease, background .15s ease, color .15s ease;
}
.mst-acct-priv .mst-acct-btn:hover { filter: brightness(.92); }
.mst-acct-priv .mst-acct-btn--ghost {
	background: #fff;
	color: var(--mst-acct-brand);
}
.mst-acct-priv .mst-acct-btn--ghost:hover { background: var(--mst-acct-brand); color: #fff; filter: none; }
/* Zona de perigo */
.mst-priv-danger {
	border-color: #e3b9b3;
	background: #fcf4f2;
}
.mst-priv-danger .mst-priv-h { color: #b3261e; }
.mst-acct-btn--danger {
	background: #b3261e !important;
	border-color: #b3261e !important;
	color: #fff !important;
}
.mst-acct-btn--danger:hover { filter: brightness(.92); }
