.ps-ipc-checkout {
	max-width: 540px;
	margin: 0 auto;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, sans-serif;
	color: #1a1f36;
	line-height: 1.5;
}

/* ---- Form container ---- */
.ps-ipc-form {
	background: #fff;
	border: 1px solid #e2e6ed;
	border-radius: 10px;
	padding: 28px 24px;
}

/* ---- Step indicator (tab bar) ---- */
.ps-ipc-steps {
	display: flex;
	gap: 16px;
	margin: 0 0 24px 0; /* Removed negative margins to align with fields */
	background: transparent;
	border-radius: 0;
	overflow: visible;
}

.ps-ipc-step {
	flex: 1;
	display: flex;
	align-items: center;
	gap: 16px;
	padding: 14px 18px;
	border-radius: 8px; /* Rounded corners for the individual tabs */
	border: 1px solid #e2e6ed; /* Subtle border for the cards */
	transition: all 0.2s ease;
}

.ps-ipc-step--active {
	background: #fff;
	border-color: #e2e6ed;
}

.ps-ipc-step--inactive {
	background: #f8f9fb; /* Light gray background for inactive tab */
}

/* Prevent theme button rules from affecting step tabs */
.ps-ipc-checkout .ps-ipc-step--inactive {
	background-color: #f8f9fb;
}

.ps-ipc-checkout button.ps-ipc-step {
	border: 1px solid #e2e6ed;
	color: inherit;
	font-family: inherit;
	text-align: left;
	cursor: pointer;
}

.ps-ipc-step__circle {
	width: 36px;
	height: 36px;
	padding: 4px 0 0 1px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 15px;
	font-weight: 500;
	flex-shrink: 0;
	transition: all 0.2s ease;
	background-color: transparent;
	box-sizing: border-box;
}

/* Make both circles hollow (transparent backgrounds) to match the screenshots */
.ps-ipc-step--active .ps-ipc-step__circle {
	color: #1f3a5f;
	border: 1px solid #1f3a5f;
}

.ps-ipc-step--inactive .ps-ipc-step__circle {
	color: #a8adb8;
	border: 1px solid #e2e6ed;
}

.ps-ipc-step__text {
	display: flex;
	flex-direction: column;
	line-height: 1.3;
	gap: 4px;
}

.ps-ipc-step__title {
	font-family: Georgia, "Times New Roman", serif; /* Match section headers */
	font-size: 16px;
	font-weight: 600;
}

.ps-ipc-step--active .ps-ipc-step__title {
	color: #1f3a5f;
}

.ps-ipc-step--inactive .ps-ipc-step__title {
	color: #a8adb8;
	font-weight: 500;
}

.ps-ipc-step__subtitle {
	font-size: 12px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, sans-serif;
}

.ps-ipc-step--active .ps-ipc-step__subtitle {
	color: #7a8291;
}

.ps-ipc-step--inactive .ps-ipc-step__subtitle {
	color: #a8adb8;
}

/* ---- Section headings (navy serif) ---- */
.ps-ipc-section-heading {
	font-family: Georgia, "Times New Roman", serif;
	font-size: 22px;
	font-weight: 500;
	line-height: 20px;
	color: #1f3a5f;
	margin: 0 0 16px 0;
	padding-bottom: 6px;
	border-bottom: 1px solid #e2e6ed;
	letter-spacing: normal;
}

/* ---- Banner ---- */
.ps-ipc-banner {
	padding: 10px 14px;
	border-radius: 6px;
	margin-bottom: 16px;
	font-size: 14px;
}

.ps-ipc-banner--error {
	background: #fef2f2;
	color: #dc2626;
	border: 1px solid #fecaca;
}

.ps-ipc-banner--success {
	background: #f0fdf4;
	color: #16a34a;
	border: 1px solid #bbf7d0;
}

/* ---- Form fields ---- */
.ps-ipc-fields {
	display: flex;
	flex-direction: column;
	gap: 0;
	margin-bottom: 24px;
}

.ps-ipc-field-row {
	display: flex;
	gap: 0;
}

.ps-ipc-field-row .ps-ipc-field {
	flex: 1;
}

.ps-ipc-field {
	display: flex;
	flex-direction: column;
	position: relative;
}

.ps-ipc-field label {
	display: none;
}

/* Show labels for country/state */
.ps-ipc-field--has-label label {
	display: block;
	font-size: 11px;
	color: #7a8291;
	margin: 0;
	padding: 8px 12px 0 12px;
	line-height: 1.2;
}

.ps-ipc-field--has-label input,
.ps-ipc-field--has-label select {
	padding-top: 2px !important;
	padding-bottom: 8px !important;
	border-top: none !important;
}

.ps-ipc-required {
	color: #dc2626;
}

.ps-ipc-field input,
.ps-ipc-field select {
	padding: 12px;
	border: 1px solid #d5d9e0;
	border-radius: 0;
	font-size: 14px;
	font-family: inherit;
	color: #1a1f36;
	background: #fff;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
	-webkit-appearance: none;
	appearance: none;
	margin: 0;
}

.ps-ipc-field select {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%237a8291' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
	padding-right: 32px;
}

.ps-ipc-field-row .ps-ipc-field:not(:first-child) input,
.ps-ipc-field-row .ps-ipc-field:not(:first-child) select {
	border-left: none;
}

/* Collapse vertical borders */
.ps-ipc-fields > .ps-ipc-field + .ps-ipc-field > input,
.ps-ipc-fields > .ps-ipc-field + .ps-ipc-field > select,
.ps-ipc-fields > .ps-ipc-field-row + .ps-ipc-field > input,
.ps-ipc-fields > .ps-ipc-field-row + .ps-ipc-field > select,
.ps-ipc-fields > .ps-ipc-field + .ps-ipc-field-row > .ps-ipc-field > input,
.ps-ipc-fields > .ps-ipc-field + .ps-ipc-field-row > .ps-ipc-field > select,
.ps-ipc-fields > .ps-ipc-field-row + .ps-ipc-field-row > .ps-ipc-field > input,
.ps-ipc-fields > .ps-ipc-field-row + .ps-ipc-field-row > .ps-ipc-field > select,
.ps-ipc-fields > .ps-ipc-field--has-label + .ps-ipc-field > input,
.ps-ipc-fields > .ps-ipc-field--has-label + .ps-ipc-field-row > .ps-ipc-field > input {
	border-top: none;
}


.ps-ipc-fields .ps-ipc-field + .ps-ipc-field--has-label,
.ps-ipc-fields .ps-ipc-field-row + .ps-ipc-field--has-label {
	border: 1px solid #d5d9e0;
	border-top: none;
}

.ps-ipc-field--has-label {
	border: 1px solid #d5d9e0;
}

.ps-ipc-field--has-label input,
.ps-ipc-field--has-label select {
	border: none !important;
}

/* ---- Border radius ---- */
.ps-ipc-fields > .ps-ipc-field-row:first-child > .ps-ipc-field:first-child input,
.ps-ipc-fields > .ps-ipc-field:first-child > input,
.ps-ipc-fields > .ps-ipc-field:first-child > select {
	border-radius: 6px 0 0 0;
}

.ps-ipc-fields > .ps-ipc-field-row:first-child > .ps-ipc-field:last-child input,
.ps-ipc-fields > .ps-ipc-field:first-child > input {
	border-radius: 6px 6px 0 0;
}

.ps-ipc-fields > .ps-ipc-field-row:first-child > .ps-ipc-field:first-child input {
	border-radius: 6px 0 0 0;
}

.ps-ipc-fields > .ps-ipc-field-row:first-child > .ps-ipc-field:last-child input {
	border-radius: 0 6px 0 0;
}


.ps-ipc-fields > .ps-ipc-field-row:last-child > .ps-ipc-field:first-child input,
.ps-ipc-fields > .ps-ipc-field-row:last-child > .ps-ipc-field:first-child select {
	border-radius: 0 0 0 6px;
}

.ps-ipc-fields > .ps-ipc-field-row:last-child > .ps-ipc-field:last-child input,
.ps-ipc-fields > .ps-ipc-field-row:last-child > .ps-ipc-field:last-child select {
	border-radius: 0 0 6px 0;
}


.ps-ipc-fields > .ps-ipc-field:last-child > input,
.ps-ipc-fields > .ps-ipc-field:last-child > select,
.ps-ipc-fields > .ps-ipc-field--has-label:last-child {
	border-radius: 0 0 6px 6px;
}

.ps-ipc-fields > .ps-ipc-field--has-label:last-child select,
.ps-ipc-fields > .ps-ipc-field--has-label:last-child input {
	border-radius: 0 0 6px 6px !important;
}


.ps-ipc-fields > .ps-ipc-field:first-child > input,
.ps-ipc-fields > .ps-ipc-field:first-child > select {
	border-radius: 6px 6px 0 0;
}


.ps-ipc-fields > .ps-ipc-field:only-child > input {
	border-radius: 6px;
}

.ps-ipc-field input:focus,
.ps-ipc-field select:focus {
	outline: none;
	border-color: #1f3a5f;
	box-shadow: 0 0 0 2px rgba(45, 74, 122, 0.12);
	z-index: 1;
	position: relative;
}

.ps-ipc-field input::placeholder,
.ps-ipc-field select::placeholder {
	color: #9ca3af;
}

.ps-ipc-input--error {
	border-color: #dc2626 !important;
	z-index: 1;
	position: relative;
}

.ps-ipc-field-error {
	font-size: 12px;
	color: #dc2626;
	margin-top: 2px;
	padding-left: 2px;
	display: none;
}

/* ---- Saved address link ---- */
.ps-ipc-link {
	display: inline-block;
	background: none;
	border: none;
	color: #1f3a5f;
	font-size: 13px;
	cursor: pointer;
	padding: 0;
	margin-bottom: 14px;
	font-family: inherit;
	text-decoration: underline;
	text-underline-offset: 2px;
}

.ps-ipc-link:hover {
	color: #1e2a4a;
}

/* ---- Primary button (brick-red CTA) ---- */
.ps-ipc-btn {
	display: block;
	width: 100%;
	padding: 16px 24px;
	border: none;
	border-radius: 8px;
	font-size: 18px;
	font-weight: 700;
	cursor: pointer;
	font-family: inherit;
	letter-spacing: 0.02em;
	transition: background-color 0.2s ease, opacity 0.2s ease, transform 0.1s ease;
}

.ps-ipc-btn:active:not(:disabled) {
	transform: scale(0.99);
}

.ps-ipc-btn:disabled {
	opacity: 0.65;
	cursor: not-allowed;
}

.ps-ipc-btn--primary {
	background: #9e3623;
	color: #fff;
}

.ps-ipc-btn--primary:hover:not(:disabled) {
	background: #852d1c;
}

/* ---- Back button ---- */
.ps-ipc-back-btn {
	margin-top: 14px;
	text-align: center;
	width: 100%;
	color: #5a6270;
	font-size: 14px;
}

.ps-ipc-back-btn:hover {
	color: #1f3a5f;
}

/* ---- Product card (Step 2: Book section) ---- */
.ps-ipc-product-card {
	display: flex;
	align-items: flex-start;
	gap: 14px;
	margin-bottom: 20px;
}

.ps-ipc-product-card__image {
	width: 80px;
	height: auto;
	min-height: 80px;
	object-fit: cover;
	border-radius: 4px;
	flex-shrink: 0;
}

.ps-ipc-product-card__info {
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding-top: 4px;
}

.ps-ipc-product-card__name-price {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 8px;
}

.ps-ipc-product-card__name {
	font-size: 15px;
	font-weight: 600;
	color: #1a1f36;
	line-height: 1.3;
}

.ps-ipc-product-card__price {
	font-size: 16px;
	font-weight: 600;
	color: #1a1f36;
	white-space: nowrap;
}

/* ---- Quantity controls ---- */
.ps-ipc-quantity {
	display: inline-flex;
	align-items: center;
}

.ps-ipc-qty-btn {
	width: 34px;
	height: 34px;
	padding: 10px;
	border: 1px solid #d5d9e0;
	background: #fff;
	font-size: 16px;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	font-family: inherit;
	color: #5a6270;
	transition: background 0.15s ease;
}

.ps-ipc-qty-btn:first-child {
	border-radius: 4px 0 0 4px;
}

.ps-ipc-qty-btn:last-child {
	border-radius: 0 4px 4px 0;
}

.ps-ipc-qty-btn:hover {
	background: #f4f5f7;
}

.ps-ipc-qty-btn:focus {
	color: #5a6270;
	background: #fff;
	outline: none;
}

.ps-ipc-qty-value {
	width: 38px;
	height: 34px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-top: 1px solid #d5d9e0;
	border-bottom: 1px solid #d5d9e0;
	font-size: 14px;
	font-weight: 600;
	color: #1a1f36;
	background: #fff;
}

/* ---- Billing same-as-shipping checkbox ---- */
.ps-ipc-billing-same {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-bottom: 20px;
	font-size: 14px;
	color: #1a1f36;
	cursor: default;
}

.ps-ipc-billing-same input[type="checkbox"] {
	width: 18px;
	height: 18px;
	accent-color: #1f3a5f;
	cursor: pointer;
	flex-shrink: 0;
}

/* ---- Payment section ---- */
.ps-ipc-payment-section {
	margin-bottom: 24px;
}

#ps-ipc-payment-element {
	margin-bottom: 12px;
}

.ps-ipc-payment-errors {
	color: #dc2626;
	font-size: 13px;
}

/* ---- Add-on section ---- */
.ps-ipc-addon-section {
	margin-bottom: 24px;
}

.ps-ipc-addon-toggle {
	margin-bottom: 14px;
}

.ps-ipc-addon-toggle label {
	display: flex;
	align-items: center;
	gap: 10px;
	cursor: pointer;
	font-size: 14px;
	color: #1a1f36;
}

.ps-ipc-addon-toggle input[type="checkbox"] {
	width: 18px;
	height: 18px;
	accent-color: #1f3a5f;
	cursor: pointer;
	flex-shrink: 0;
}

.ps-ipc-addon-card {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-top: 14px;
}

.ps-ipc-addon-card__image {
	width: 72px;
	height: 72px;
	object-fit: cover;
	border-radius: 4px;
	background: #e8eaef;
	flex-shrink: 0;
}

.ps-ipc-addon-card__info {
	flex: 1;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
}

.ps-ipc-addon-card__name {
	font-size: 14px;
	font-weight: 700;
	color: #1a1f36;
}

.ps-ipc-addon-card__price {
	font-size: 14px;
	font-weight: 500;
	color: #1a1f36;
	white-space: nowrap;
}

/* ---- Order Summary (Step 2) ---- */
.ps-ipc-order-summary {
	margin-bottom: 24px;
}

.ps-ipc-order-lines {
	display: flex;
	flex-direction: column;
}

.ps-ipc-order-line {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 8px 0;
	font-size: 14px;
	color: #1a1f36;
}

.ps-ipc-order-line__details {
	flex: 1;
}

.ps-ipc-order-line__name {
	font-size: 14px;
	font-weight: 500;
}

.ps-ipc-order-line__qty {
	font-size: 13px;
	color: #7a8291;
}

.ps-ipc-order-line__total {
	font-weight: 500;
	white-space: nowrap;
}

.ps-ipc-order-line--separator {
	border-top: 1px solid #e2e6ed;
	margin-top: 4px;
	padding-top: 10px;
}

.ps-ipc-order-line--meta {
	font-size: 14px;
	color: #5a6270;
	padding: 4px 0;
}

.ps-ipc-order-line--total {
	border-top: 1px solid #e2e6ed;
	margin-top: 4px;
	padding-top: 10px;
	font-size: 16px;
}

.ps-ipc-order-line--total strong {
	font-weight: 700;
}

.ps-ipc-order-line__img {
	display: none;
}

/* ---- Book section ---- */
.ps-ipc-book-section {
	margin-bottom: 20px;
}

/* ---- Error page state ---- */
.ps-ipc-error {
	background: #fef2f2;
	color: #dc2626;
	padding: 12px 16px;
	border-radius: 6px;
	border: 1px solid #fecaca;
	font-size: 14px;
}

/* ---- Editor preview (admin side) ---- */
.ps-ipc-editor-preview {
	border: 1px solid #e0e0e0;
	border-radius: 8px;
	padding: 20px;
	background: #fafafa;
}

.ps-ipc-editor-preview__header {
	font-size: 14px;
	font-weight: 600;
	margin-bottom: 12px;
	display: flex;
	align-items: center;
}

.ps-ipc-editor-preview__product {
	display: flex;
	align-items: center;
	margin-bottom: 10px;
}

.ps-ipc-editor-preview__addon {
	color: #666;
	margin-bottom: 10px;
}

.ps-ipc-editor-preview__steps {
	display: flex;
	gap: 12px;
	padding-top: 10px;
	border-top: 1px solid #e0e0e0;
}

.ps-ipc-editor-preview__step {
	font-size: 13px;
	color: #999;
}

.ps-ipc-editor-preview__step--active {
	color: #1a1a1a;
	font-weight: 600;
}

/* ---- Responsive ---- */
@media (max-width: 480px) {
	.ps-ipc-form {
		padding: 20px 16px;
	}

	.ps-ipc-steps {
		margin: 0 0 20px 0;
		gap: 10px;
	}

	.ps-ipc-step {
		padding: 12px 10px;
		gap: 8px;
	}

	.ps-ipc-step__circle {
		width: 30px;
		height: 30px;
		font-size: 12px;
	}

	.ps-ipc-step__title {
		font-size: 13px;
	}

	.ps-ipc-step__subtitle {
		font-size: 11px;
	}

	.ps-ipc-field-row {
		flex-direction: column;
	}

	.ps-ipc-field-row .ps-ipc-field:not(:first-child) input,
	.ps-ipc-field-row .ps-ipc-field:not(:first-child) select {
		border-left: 1px solid #d5d9e0;
		border-top: none;
	}


	.ps-ipc-fields > .ps-ipc-field-row:first-child > .ps-ipc-field:last-child input {
		border-radius: 0;
	}

	.ps-ipc-fields > .ps-ipc-field-row:first-child > .ps-ipc-field:first-child input {
		border-radius: 6px 6px 0 0;
	}

	.ps-ipc-fields > .ps-ipc-field-row:last-child > .ps-ipc-field:first-child input,
	.ps-ipc-fields > .ps-ipc-field-row:last-child > .ps-ipc-field:first-child select {
		border-radius: 0;
	}

	.ps-ipc-fields > .ps-ipc-field-row:last-child > .ps-ipc-field:last-child input,
	.ps-ipc-fields > .ps-ipc-field-row:last-child > .ps-ipc-field:last-child select {
		border-radius: 0 0 6px 6px;
	}

	.ps-ipc-section-heading {
		font-size: 18px;
	}

	.ps-ipc-btn {
		font-size: 16px;
		padding: 14px 20px;
	}
}
