/* Deja aire debajo del contenido para que el boton flotante nunca tape el
   footer al llegar al final de la pagina. */
.site-footer {
	margin-bottom: 84px;
}

.pyc-fab {
	position: fixed;
	right: 20px;
	bottom: 20px;
	z-index: 9999;
	background: var(--pyc-orange, #F09848);
	color: #fff;
	border: none;
	border-radius: 999px;
	padding: 16px 22px;
	font-family: var(--pyc-font-body, sans-serif);
	font-weight: 600;
	font-size: 0.98rem;
	display: flex;
	align-items: center;
	gap: 8px;
	box-shadow: 0 10px 26px rgba(240, 152, 72, 0.45);
	cursor: pointer;
	transition: transform 0.15s ease;
}

.pyc-fab:hover { transform: translateY(-2px); }

.pyc-fab-contador {
	background: #fff;
	color: var(--pyc-orange-dark, #D67D2E);
	border-radius: 999px;
	min-width: 22px;
	height: 22px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 0.8rem;
	font-weight: 700;
	padding: 0 6px;
}

.pyc-overlay {
	position: fixed;
	inset: 0;
	background: rgba(18, 54, 66, 0.55);
	z-index: 10000;
	display: flex;
	align-items: flex-end;
	justify-content: center;
}

.pyc-overlay[hidden] { display: none; }

.pyc-drawer {
	background: #fff;
	width: 100%;
	max-width: 480px;
	max-height: 88vh;
	border-radius: 20px 20px 0 0;
	display: flex;
	flex-direction: column;
	font-family: var(--pyc-font-body, sans-serif);
	animation: pyc-slide-up 0.25s ease;
}

@media (min-width: 640px) {
	.pyc-overlay { align-items: center; }
	.pyc-drawer { border-radius: 20px; max-height: 85vh; }
}

@keyframes pyc-slide-up {
	from { transform: translateY(30px); opacity: 0; }
	to { transform: translateY(0); opacity: 1; }
}

.pyc-drawer-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 18px 20px;
	border-bottom: 1px solid #eee;
}

.pyc-drawer-header h2 {
	margin: 0;
	font-family: var(--pyc-font-heading, serif);
	color: var(--pyc-teal-dark, #123642);
	font-size: 1.3rem;
}

.pyc-cerrar {
	background: #f2f2f2;
	border: none;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	font-size: 1rem;
	cursor: pointer;
}

.pyc-drawer-body {
	padding: 18px 20px;
	overflow-y: auto;
	flex: 1;
}

.pyc-seccion {
	margin-bottom: 22px;
}

.pyc-seccion h3 {
	font-family: var(--pyc-font-heading, serif);
	color: var(--pyc-teal-dark, #123642);
	font-size: 1.05rem;
	margin: 0 0 12px;
}

#pyc-seccion-codigo label {
	display: block;
	font-weight: 600;
	color: var(--pyc-teal-dark, #123642);
	margin-bottom: 6px;
}

.pyc-obligatorio { color: var(--pyc-orange, #F09848); }

#pyc-codigo,
.pyc-campos input,
.pyc-campos textarea {
	width: 100%;
	box-sizing: border-box;
	padding: 12px 14px;
	border: 1.5px solid #ddd;
	border-radius: 10px;
	font-size: 1rem;
	font-family: inherit;
	margin-bottom: 10px;
}

#pyc-codigo:focus,
.pyc-campos input:focus,
.pyc-campos textarea:focus {
	border-color: var(--pyc-teal, #287090);
	outline: none;
}

.pyc-codigo-ayuda {
	font-size: 0.82rem;
	color: #777;
	margin: 4px 0;
}

.pyc-codigo-estado {
	font-size: 0.88rem;
	font-weight: 600;
	min-height: 1.2em;
	margin: 4px 0 0;
}

.pyc-codigo-estado.ok { color: #2e7d32; }
.pyc-codigo-estado.error { color: #c62828; }

.pyc-lista-productos {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.pyc-producto-row {
	display: flex;
	align-items: center;
	gap: 12px;
	border: 1px solid #eee;
	border-radius: 12px;
	padding: 10px;
}

.pyc-producto-row img {
	width: 56px;
	height: 56px;
	object-fit: cover;
	border-radius: 8px;
	flex-shrink: 0;
}

.pyc-producto-info {
	flex: 1;
	min-width: 0;
}

.pyc-producto-info strong {
	display: block;
	color: var(--pyc-teal-dark, #123642);
	font-size: 0.96rem;
}

.pyc-producto-info span {
	display: block;
	font-size: 0.85rem;
	color: #777;
}

.pyc-producto-info .pyc-descuento-badge {
	display: inline-block;
	margin-top: 3px;
	background: #fef1e2;
	color: var(--pyc-orange-dark, #D67D2E);
	font-size: 0.72rem;
	font-weight: 700;
	padding: 2px 8px;
	border-radius: 999px;
}

.pyc-stepper {
	display: flex;
	align-items: center;
	gap: 8px;
	flex-shrink: 0;
}

.pyc-stepper button {
	width: 30px;
	height: 30px;
	border-radius: 50%;
	border: 1.5px solid var(--pyc-teal, #287090);
	background: #fff;
	color: var(--pyc-teal, #287090);
	font-size: 1.1rem;
	line-height: 1;
	cursor: pointer;
}

.pyc-stepper button:disabled {
	opacity: 0.35;
	cursor: not-allowed;
}

.pyc-stepper span {
	min-width: 20px;
	text-align: center;
	font-weight: 700;
}

.pyc-mensaje {
	padding: 12px 14px;
	border-radius: 10px;
	font-size: 0.9rem;
	margin-top: 8px;
}

.pyc-mensaje.error {
	background: #fdecea;
	color: #c62828;
}

.pyc-mensaje.exito {
	background: #eaf6ea;
	color: #2e7d32;
}

.pyc-drawer-footer {
	padding: 16px 20px;
	border-top: 1px solid #eee;
	display: flex;
	align-items: center;
	gap: 14px;
}

.pyc-total {
	display: flex;
	flex-direction: column;
	line-height: 1.1;
}

.pyc-total span {
	font-size: 0.75rem;
	color: #888;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.pyc-total strong {
	font-size: 1.25rem;
	color: var(--pyc-teal-dark, #123642);
}

.pyc-boton-principal {
	flex: 1;
	background: var(--pyc-orange, #F09848);
	color: #fff;
	border: none;
	border-radius: 999px;
	padding: 14px;
	font-weight: 700;
	font-size: 1rem;
	cursor: pointer;
	transition: background 0.15s ease;
}

.pyc-boton-principal:disabled {
	background: #ddd;
	color: #999;
	cursor: not-allowed;
}

.pyc-boton-principal:not(:disabled):hover {
	background: var(--pyc-orange-dark, #D67D2E);
}

/* Reemplaza el boton nativo de WooCommerce en el grid */
ul.products li.product .pyc-add-item {
	width: 100%;
	background: var(--pyc-orange, #F09848);
	color: #fff;
	border: none;
	border-radius: 999px;
	font-weight: 600;
	padding: 12px 20px;
	cursor: pointer;
}

ul.products li.product .pyc-add-item:hover {
	background: var(--pyc-orange-dark, #D67D2E);
}
