/**
 * Afro Beleza — Estilos do frontend (shortcode de marcações).
 * Design system baseado na identidade da marca.
 */

.afrobeleza-booking {
	--primary-color: #B27B6B;
	--primary-hover: #9E6A5B;
	--text-dark: #2C2825;
	--text-light: #666666;
	--bg-cream: #FAF7F2;
	--white: #FFFFFF;
	--gold-accent: #CFA461;
	--font-heading: 'Playfair Display', Georgia, serif;
	--font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

	--radius: 14px;
	--radius-sm: 10px;
	--shadow: 0 8px 30px rgba(44, 40, 37, 0.08);
	--shadow-soft: 0 2px 10px rgba(44, 40, 37, 0.06);
	--transition: all 0.25s ease;

	max-width: 720px;
	margin: 0 auto;
	padding: 28px;
	background: var(--bg-cream);
	border-radius: var(--radius);
	box-shadow: var(--shadow);
	font-family: var(--font-body);
	color: var(--text-dark);
	box-sizing: border-box;
}

.afrobeleza-booking *,
.afrobeleza-booking *::before,
.afrobeleza-booking *::after {
	box-sizing: border-box;
}

/* ---------- Passos (stepper) ---------- */
.ab-steps {
	display: flex;
	justify-content: space-between;
	list-style: none;
	margin: 0 0 30px;
	padding: 0;
	counter-reset: step;
	position: relative;
}

.ab-steps::before {
	content: "";
	position: absolute;
	top: 18px;
	left: 8%;
	right: 8%;
	height: 2px;
	background: rgba(178, 123, 107, 0.25);
	z-index: 0;
}

.ab-step {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	font-size: 13px;
	font-weight: 500;
	color: var(--text-light);
	flex: 1;
}

.ab-step span {
	display: grid;
	place-items: center;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	background: var(--white);
	border: 2px solid rgba(178, 123, 107, 0.35);
	color: var(--text-light);
	font-weight: 600;
	transition: var(--transition);
}

.ab-step.is-active span {
	background: var(--primary-color);
	border-color: var(--primary-color);
	color: var(--white);
}

.ab-step.is-active {
	color: var(--text-dark);
}

.ab-step.is-done span {
	background: var(--gold-accent);
	border-color: var(--gold-accent);
	color: var(--white);
}

/* ---------- Títulos ---------- */
.ab-title {
	font-family: var(--font-heading);
	font-size: 26px;
	font-weight: 600;
	margin: 0 0 18px;
	color: var(--text-dark);
}

.ab-resumo-servico,
.ab-resumo-data {
	margin: -8px 0 18px;
	color: var(--text-light);
	font-size: 14px;
}

/* ---------- Serviços ---------- */
.ab-servicos {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 14px;
}

.ab-servico-card {
	text-align: left;
	background: var(--white);
	border: 1px solid rgba(178, 123, 107, 0.18);
	border-radius: var(--radius-sm);
	padding: 18px;
	cursor: pointer;
	transition: var(--transition);
	box-shadow: var(--shadow-soft);
	font-family: var(--font-body);
}

.ab-servico-card:hover {
	border-color: var(--primary-color);
	transform: translateY(-3px);
	box-shadow: 0 10px 24px rgba(178, 123, 107, 0.18);
}

.ab-servico-card.is-selected {
	border-color: var(--primary-color);
	background: linear-gradient(180deg, #fff, #fbf3ee);
}

.ab-servico-card__nome {
	font-family: var(--font-heading);
	font-size: 18px;
	font-weight: 600;
	margin: 0 0 6px;
}

.ab-servico-card__desc {
	font-size: 13px;
	color: var(--text-light);
	margin: 0 0 12px;
	line-height: 1.5;
}

.ab-servico-card__meta {
	display: flex;
	justify-content: space-between;
	align-items: center;
	border-top: 1px dashed rgba(178, 123, 107, 0.25);
	padding-top: 10px;
}

.ab-servico-card__preco {
	font-weight: 600;
	color: var(--primary-hover);
	font-size: 16px;
}

.ab-servico-card__duracao {
	font-size: 12px;
	color: var(--text-light);
	background: var(--bg-cream);
	padding: 4px 10px;
	border-radius: 999px;
}

/* ---------- Calendário ---------- */
.ab-calendar {
	background: var(--white);
	border-radius: var(--radius-sm);
	padding: 18px;
	box-shadow: var(--shadow-soft);
	margin-bottom: 18px;
}

.ab-calendar__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 14px;
}

.ab-calendar__month {
	font-family: var(--font-heading);
	font-size: 18px;
	font-weight: 600;
	text-transform: capitalize;
}

.ab-cal-nav {
	width: 38px;
	height: 38px;
	border: none;
	border-radius: 50%;
	background: var(--bg-cream);
	color: var(--primary-hover);
	font-size: 20px;
	line-height: 1;
	cursor: pointer;
	transition: var(--transition);
}

.ab-cal-nav:hover:not(:disabled) {
	background: var(--primary-color);
	color: var(--white);
}

.ab-cal-nav:disabled {
	opacity: 0.35;
	cursor: not-allowed;
}

.ab-calendar__weekdays,
.ab-calendar__grid {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
	gap: 6px;
}

.ab-calendar__weekdays {
	margin-bottom: 8px;
}

.ab-weekday {
	text-align: center;
	font-size: 12px;
	font-weight: 600;
	color: var(--text-light);
	text-transform: uppercase;
	letter-spacing: 0.04em;
}

.ab-day {
	aspect-ratio: 1 / 1;
	display: grid;
	place-items: center;
	border: none;
	border-radius: var(--radius-sm);
	background: transparent;
	color: var(--text-dark);
	font-size: 14px;
	font-family: var(--font-body);
	cursor: pointer;
	transition: var(--transition);
}

.ab-day.is-empty {
	visibility: hidden;
}

.ab-day.is-available {
	background: rgba(178, 123, 107, 0.10);
	color: var(--primary-hover);
	font-weight: 500;
}

.ab-day.is-available:hover {
	background: var(--primary-color);
	color: var(--white);
}

.ab-day.is-disabled {
	color: #c9c2bb;
	cursor: not-allowed;
	background: transparent;
}

.ab-day.is-today {
	box-shadow: inset 0 0 0 2px var(--gold-accent);
}

.ab-day.is-selected {
	background: var(--primary-color);
	color: var(--white);
	font-weight: 600;
}

/* ---------- Slots de horas ---------- */
.ab-slots {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
	gap: 10px;
	margin-bottom: 18px;
}

.ab-slot {
	padding: 12px 8px;
	border: 1px solid rgba(178, 123, 107, 0.25);
	border-radius: var(--radius-sm);
	background: var(--white);
	color: var(--text-dark);
	font-family: var(--font-body);
	font-size: 15px;
	font-weight: 500;
	cursor: pointer;
	transition: var(--transition);
}

.ab-slot:hover {
	border-color: var(--primary-color);
	background: rgba(178, 123, 107, 0.08);
}

.ab-slot.is-selected {
	background: var(--primary-color);
	border-color: var(--primary-color);
	color: var(--white);
}

/* ---------- Formulário ---------- */
.ab-form {
	display: grid;
	gap: 16px;
}

.ab-field {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.ab-field label {
	font-size: 14px;
	font-weight: 500;
	color: var(--text-dark);
}

.ab-field input {
	padding: 12px 14px;
	border: 1px solid rgba(178, 123, 107, 0.3);
	border-radius: var(--radius-sm);
	font-family: var(--font-body);
	font-size: 15px;
	background: var(--white);
	color: var(--text-dark);
	transition: var(--transition);
}

.ab-field input:focus {
	outline: none;
	border-color: var(--primary-color);
	box-shadow: 0 0 0 3px rgba(178, 123, 107, 0.15);
}

.ab-resumo-final {
	background: var(--white);
	border-radius: var(--radius-sm);
	padding: 16px 18px;
	margin-bottom: 18px;
	box-shadow: var(--shadow-soft);
	border-left: 4px solid var(--gold-accent);
}

.ab-resumo-final strong {
	color: var(--primary-hover);
}

.ab-form-erro {
	background: #fcebea;
	color: #b32d2e;
	border-radius: var(--radius-sm);
	padding: 10px 14px;
	font-size: 14px;
	margin: 0;
}

.ab-form-actions {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	margin-top: 6px;
}

/* ---------- Botões ---------- */
.ab-btn {
	padding: 13px 24px;
	border: none;
	border-radius: var(--radius-sm);
	font-family: var(--font-body);
	font-size: 15px;
	font-weight: 600;
	cursor: pointer;
	transition: var(--transition);
}

.ab-btn--primary {
	background: var(--primary-color);
	color: var(--white);
	box-shadow: 0 6px 16px rgba(178, 123, 107, 0.3);
}

.ab-btn--primary:hover {
	background: var(--primary-hover);
	transform: translateY(-2px);
}

.ab-btn--primary:disabled {
	opacity: 0.6;
	cursor: not-allowed;
	transform: none;
}

.ab-btn--ghost {
	background: transparent;
	color: var(--text-light);
	padding-left: 0;
}

.ab-btn--ghost:hover {
	color: var(--primary-hover);
}

/* ---------- Sucesso ---------- */
.ab-success {
	text-align: center;
	padding: 30px 10px;
}

.ab-success__icon {
	width: 76px;
	height: 76px;
	margin: 0 auto 18px;
	border-radius: 50%;
	display: grid;
	place-items: center;
	background: var(--gold-accent);
	color: var(--white);
	font-size: 38px;
	animation: ab-pop 0.4s ease;
}

@keyframes ab-pop {
	0% { transform: scale(0); }
	70% { transform: scale(1.15); }
	100% { transform: scale(1); }
}

.ab-success__msg {
	color: var(--text-light);
	font-size: 16px;
	margin-bottom: 22px;
	line-height: 1.6;
}

/* ---------- Estados utilitários ---------- */
.ab-loading {
	color: var(--text-light);
	font-style: italic;
}

.ab-empty {
	color: var(--text-light);
	text-align: center;
	padding: 20px;
}

/* ---------- Abas (Marcar / Gerir) ---------- */
.ab-tabs {
	display: flex;
	gap: 6px;
	background: rgba(178, 123, 107, 0.10);
	padding: 5px;
	border-radius: 999px;
	margin: 0 auto 26px;
	max-width: 420px;
}

.ab-tab {
	flex: 1;
	border: none;
	background: transparent;
	padding: 11px 16px;
	border-radius: 999px;
	font-family: var(--font-body);
	font-size: 14px;
	font-weight: 600;
	color: var(--text-light);
	cursor: pointer;
	transition: var(--transition);
}

.ab-tab.is-active {
	background: var(--white);
	color: var(--primary-hover);
	box-shadow: var(--shadow-soft);
}

/* ---------- Caixa do código de reserva ---------- */
.ab-code-box {
	background: var(--white);
	border: 1px dashed var(--gold-accent);
	border-radius: var(--radius-sm);
	padding: 20px;
	margin: 0 auto 24px;
	max-width: 380px;
	display: flex;
	flex-direction: column;
	gap: 8px;
	align-items: center;
}

.ab-code-box__label {
	font-size: 12px;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--text-light);
}

.ab-code-box__value {
	display: flex;
	align-items: center;
	gap: 10px;
	font-family: var(--font-body);
	font-size: 26px;
	font-weight: 700;
	letter-spacing: 2px;
	color: var(--primary-hover);
}

.ab-code-copy {
	border: none;
	background: var(--bg-cream);
	border-radius: 8px;
	width: 36px;
	height: 36px;
	font-size: 16px;
	cursor: pointer;
	transition: var(--transition);
}

.ab-code-copy:hover {
	background: rgba(178, 123, 107, 0.18);
}

.ab-code-box__hint {
	font-size: 12px;
	color: var(--text-light);
	text-align: center;
	line-height: 1.5;
}

/* ---------- Cartão de reserva (modo gerir) ---------- */
.ab-reserva-card {
	background: var(--white);
	border-radius: var(--radius-sm);
	padding: 22px;
	box-shadow: var(--shadow-soft);
	margin-bottom: 18px;
}

.ab-reserva-codigo {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	font-size: 22px;
	font-weight: 700;
	letter-spacing: 1px;
	color: var(--primary-hover);
	border-bottom: 1px solid #f0e9e3;
	padding-bottom: 14px;
	margin-bottom: 14px;
}

.ab-reserva-lista {
	margin: 0;
}

.ab-reserva-linha {
	display: flex;
	justify-content: space-between;
	gap: 16px;
	padding: 8px 0;
}

.ab-reserva-linha dt {
	color: var(--text-light);
	font-size: 14px;
	margin: 0;
}

.ab-reserva-linha dd {
	margin: 0;
	font-weight: 600;
	text-align: right;
	color: var(--text-dark);
}

/* Estado (badge) no modo gerir */
.ab-status {
	font-size: 12px;
	font-weight: 600;
	padding: 4px 12px;
	border-radius: 999px;
	letter-spacing: 0.02em;
}

.ab-status--pendente {
	background: #fff4e0;
	color: #9a6b00;
}

.ab-status--confirmado {
	background: #e3f4e8;
	color: #1f7a3d;
}

.ab-status--cancelado {
	background: #fcebea;
	color: #b32d2e;
}

/* Botão de perigo (cancelar) */
.ab-btn--danger {
	background: #fcebea;
	color: #b32d2e;
}

.ab-btn--danger:hover {
	background: #b32d2e;
	color: var(--white);
	transform: translateY(-2px);
}

.ab-btn--danger:disabled {
	opacity: 0.6;
	cursor: not-allowed;
	transform: none;
}

/* Mensagem de sucesso em formulário */
.ab-form-sucesso {
	background: #e3f4e8;
	color: #1f7a3d;
	border-radius: var(--radius-sm);
	padding: 10px 14px;
	font-size: 14px;
	margin: 0;
}

/* ---------- Responsivo ---------- */
@media (max-width: 600px) {
	.afrobeleza-booking { padding: 18px; }
	.ab-title { font-size: 22px; }
	.ab-step { font-size: 11px; }
	.ab-servicos { grid-template-columns: 1fr; }
}
