/**
 * AWCP Multi-Step Checkout Styles
 * Emulates Pet Drugs Online checkout design
 */

/* ============================================
   Forgot Password Page - CRITICAL - MUST BE FIRST
   High specificity to override theme styles
   ============================================ */

.awcp-forgot-password-section {
	display: block !important;
}

.awcp-forgot-password-section .awcp-auth-radio-header {
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
}

.awcp-forgot-password-section .awcp-auth-description {
	color: #666 !important;
	margin-bottom: 25px !important;
}

.awcp-forgot-password-section .awcp-auth-note {
	margin-top: 25px !important;
	padding-top: 25px !important;
	border-top: 1px solid #eee !important;
}

.awcp-forgot-password-section .awcp-auth-note p {
	margin: 0 !important;
	font-size: 13px !important;
	color: #666 !important;
	line-height: 1.6 !important;
}

.awcp-forgot-password-form .awcp-auth-buttons {
	display: flex !important;
	gap: 15px !important;
	margin-top: 25px !important;
}

.awcp-forgot-password-form .awcp-auth-buttons .button,
.awcp-forgot-password-form .awcp-auth-buttons .button-secondary {
	flex: 1 !important;
}

/* ===== Main Wrapper ===== */
.awcp-multistep-checkout-wrapper {
	/*max-width: 1200px;*/
	margin: 0 auto;
	/*padding: 20px;*/
	/*background: #f8f8f7;*/
}

/* ===== Drug Class Questions ===== */
.awcp-drug-class-questions {
	margin-top: 20px;
	/* Clean integration with existing form - no extra styling */
}

.awcp-drug-class-info {
	margin-bottom: 20px;
}

.awcp-questions-wrapper {
	display: grid;
	grid-template-columns: 1fr;
	gap: 15px; /* Reduced from 20px since dropdowns are more compact */
}

/* Two-column layout on desktop */
@media (min-width: 768px) {
	.awcp-questions-wrapper {
		grid-template-columns: repeat(2, 1fr);
		gap: 15px 20px; /* row-gap: 15px, column-gap: 20px */
	}
	
	/* Full-width for text inputs and consent only */
	.awcp-question-group:has(.awcp-text-group),
	.awcp-question-group:has(.awcp-consent-group) {
		grid-column: 1 / -1;
	}
}

.awcp-question-group {
	padding: 0;
	background: transparent;
	border-radius: 0;
	border: none;
}

.awcp-conditional-question {
	display: none;
}

.awcp-conditional-question.active {
	display: block;
}


/* Radio Field Styling */
.awcp-radio-fieldset {
	border: none;
	padding: 0;
	margin: 0;
}

.awcp-radio-fieldset legend {
	font-size: 15px;
	font-weight: 600;
	color: #2c3e50;
	margin-bottom: 12px;
	padding: 0;
}

.awcp-radio-options {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.awcp-radio-label {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px 15px;
	background: #f8f9fa;
	border: 2px solid #e0e0e0;
	border-radius: 8px;
	cursor: pointer;
	transition: all 0.2s ease;
	font-size: 14px;
	font-weight: 500;
}

.awcp-radio-label:hover {
	background: #e8f4f8;
	border-color: #9a9484;
}

.awcp-radio-label input[type="radio"] {
	width: 18px;
	height: 18px;
	margin: 0;
	cursor: pointer;
	accent-color: #c1cfb5;
}

.awcp-radio-label input[type="radio"]:checked + span {
	color: #2c3e50;
	font-weight: 600;
}

.awcp-radio-label:has(input[type="radio"]:checked) {
	background: #f5f8f3;
	border-color: #c1cfb5;
	box-shadow: 0 2px 4px rgba(193, 207, 181, 0.2);
}

/* Consent Field Styling */
.awcp-consent-group {
	padding: 0;
}

.awcp-consent-label {
	font-size: 15px;
	font-weight: 600;
	color: #2c3e50;
	margin-bottom: 12px;
}

.awcp-consent-checkbox-label {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	padding: 15px;
	background: #f8f9fa;
	border: 2px solid #e0e0e0;
	border-radius: 8px;
	cursor: pointer;
	transition: all 0.2s ease;
	font-size: 14px;
	line-height: 1.5;
}

.awcp-consent-checkbox-label:hover {
	background: #e8f4f8;
	border-color: #9a9484;
}

.awcp-consent-checkbox-label input[type="checkbox"] {
	width: 18px;
	height: 18px;
	margin-top: 2px;
	cursor: pointer;
	accent-color: #9a9484;
	flex-shrink: 0;
}

.awcp-consent-checkbox-label:has(input[type="checkbox"]:checked) {
	background: #e8f4f8;
	border-color: #9a9484;
	box-shadow: 0 2px 4px rgba(154, 148, 132, 0.15);
}

.awcp-consent-checkbox-label input[type="checkbox"]:checked + span {
	color: #2c3e50;
	font-weight: 500;
}

/* Required indicator */
.awcp-question-group .required {
	color: #e53935;
	font-weight: 700;
	margin-left: 4px;
}

/* ===== Progress Bar ===== */
/*.awcp-progress-bar {
	background: #fff;
	border: 1px solid #c1cfb5;
	border-radius: 8px;
	padding: 30px 20px;
	margin-bottom: 30px;
	box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}*/
.awcp-progress-bar {
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0px 30px 70px 0px rgba(0, 0, 0, 0.05);
}

.awcp-progress-back {
	margin-bottom: 20px;
}

.awcp-back-link {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 14px;
	color: #2c3e50;
	text-decoration: none;
	font-weight: 500;
}

.awcp-back-link:hover {
	color: #9a9484;
}

.awcp-back-icon {
	font-size: 18px;
}

.awcp-progress-steps {
	display: flex;
	align-items: center;
	justify-content: space-between;
	max-width: 900px;
	margin: 0 auto;
}

.awcp-progress-step {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	flex: 1;
	position: relative;
}

.awcp-step-circle {
	width: 50px;
	height: 50px;
	border-radius: 50%;
	background: #c1cfb5;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 20px;
	font-weight: 600;
	color: #757575;
	transition: all 0.3s ease;
	border: 3px solid #c1cfb5;
}

.awcp-step-current .awcp-step-circle {
	background: #9a9484;
	border-color: #9a9484;
	color: #fff;
}

.awcp-step-completed .awcp-step-circle {
	background: #61ce70;
	border-color: #61ce70;
	color: #fff;
}

.awcp-step-locked .awcp-step-circle {
	opacity: 0.5;
	color: #ffffff;
}

.awcp-step-label {
	font-size: 14px;
	font-weight: 500;
	color: #757575;
	text-align: left;
	/*max-width: 120px;*/
}

/* Clickable step links */
.awcp-step-link {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	text-decoration: none;
	cursor: pointer;
}

.awcp-step-link:hover .awcp-step-circle {
	transform: scale(1.05);
	box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.awcp-step-link:hover .awcp-step-label {
	color: #9a9484;
}

.awcp-step-completed .awcp-step-link:hover .awcp-step-circle {
	background: #45a049;
	border-color: #45a049;
}

.awcp-step-current .awcp-step-label {
	color: #9a9484;
	font-weight: 600;
}

.awcp-step-completed .awcp-step-label {
	color: #2c3e50;
}

.awcp-step-arrow {
	flex: 0 0 30px;
	text-align: center;
	color: #bdbdbd;
	font-size: 20px;
	margin-top: -30px;
}

/* ===== Content Area ===== */
/*.awcp-multistep-content {
	background: #fff;
	border: 1px solid #c1cfb5;
	border-radius: 8px;
	padding: 40px;
	box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}*/
.awcp-multistep-content {
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0px 30px 70px 0px rgba(0, 0, 0, 0.05);
}
.awcp-multistep-content h2 {
	font-size: 28px;
	font-weight: 600;
	color: #2c3e50;
	margin-bottom: 20px;
}

/* ===== Authentication Step ===== */
.awcp-auth-section {
	/*border: 2px solid #c1cfb5;*/
	border-radius: 8px;
	margin-bottom: 20px;
	overflow: hidden;
	transition: all 0.3s ease;
}

.awcp-auth-section:has(.awcp-auth-radio:checked) {
	border-color: #9a9484;
}

.awcp-auth-radio-header {
	background: #ece8e4;
	padding: 20px;
	cursor: pointer;
	display: flex;
	align-items: center;
	gap: 15px;
}

.awcp-auth-radio {
	width: 20px;
	height: 20px;
	cursor: pointer;
}

.awcp-auth-label {
	cursor: pointer;
	flex: 1;
	margin: 0;
}

.awcp-auth-title {
	font-size: 18px;
	/*font-weight: 600;*/
	color: #414042;
}

.awcp-auth-content {
	padding: 30px;
	background: #f8f8f7;
}

.awcp-auth-description {
	color: #666;
	margin-bottom: 25px;
}

.form-row {
	margin-bottom: 20px;
}

.form-row-wide {
	clear: both;
}

.form-row-first,
.form-row-last {
	width: 48% !important;
	float: left;
}

.form-row-first {
	margin-right: 4%;
}

.form-row-last {
	clear: none;
}

@media (max-width: 768px) {
	.form-row-first,
	.form-row-last {
		width: 100% !important;
		float: none;
		margin-right: 0;
	}
	
	.awcp-auth-content {
	padding: 15px;
}
}

.form-row label {
	display: block;
	font-weight: 500;
	margin-bottom: 8px;
	color: #2c3e50;
}

.form-row .required {
	color: #d32f2f;
}

.form-row input[type="email"],
.form-row input[type="password"],
.form-row input[type="text"],
.form-row input#awcp_new_pet_weight,
.form-row input#awcp_new_pet_dob,
.form-row select {
	width: 100%;
	padding: 12px 15px;
	/*border: 1px solid #c1cfb5;*/
	border: 1px solid #d9d6d0;
	border-radius: 4px;
	font-size: 14px;
	transition: border-color 0.3s;
}

.form-row input:focus,
.form-row select:focus {
	outline: none;
	border-color: #9a9484;
}

img.awcp-pet-icons {
    width: 40px;
}
.awcp-password-hint {
	display: block;
	color: #757575;
	font-size: 12px;
	margin-top: 5px;
}

.awcp-recaptcha-notice {
	margin: 20px 0;
}

.awcp-recaptcha-notice small {
	color: #757575;
	font-size: 12px;
}

.awcp-recaptcha-notice a {
	color: #9a9484;
	text-decoration: none;
}

.awcp-auth-buttons {
	display: flex;
	gap: 15px;
	flex-wrap: wrap;
	text-align: center;
}

.button,
.button-secondary {
	padding: 12px 24px;
	font-size: 15px;
	font-weight: 600;
	border-radius: 30px;
	cursor: pointer;
	transition: all 0.3s;
	border: none;
}
.button-secondary.awcp-back-button, .button-secondary.awcp-prev-section {
    background: #c5b38f !important;
    border-color: #c5b38f !important;
    margin-right: 10px;
}
button#place_order {
    padding: 12px 24px !important;
    width: 100%;
    text-align: center;
}
.button {
	background: #9a9484;
	color: #fff;
}

.button:hover {
	background: #9a9484;
}

.button-secondary {
	background: #fff;
	color: #9a9484;
	border: 2px solid #9a9484;
}

.button-secondary:hover {
	background: #f5f5f5;
}

/* ===== Logged In State ===== */
.awcp-auth-logged-in {
	text-align: center;
	padding: 40px;
}

.awcp-success-message {
	margin-bottom: 30px;
}

.awcp-checkmark {
	display: inline-block;
	width: 60px;
	height: 60px;
	line-height: 60px;
	background: #61ce70;
	color: #fff;
	border-radius: 50%;
	font-size: 36px;
	margin-bottom: 20px;
}

.awcp-account-details {
	background: #f5f5f5;
	border-radius: 8px;
	padding: 20px;
	margin: 20px 0;
	text-align: left;
	max-width: 400px;
	margin-left: auto;
	margin-right: auto;
}

.awcp-logout-link {
	color: #9a9484;
	text-decoration: none;
	font-size: 14px;
}

/* ===== Pets & Prescriptions Step ===== */
.awcp-pets-rx-intro {
	background: #ddded8;
	/*border: 1px solid #c5b38f;*/
	border-radius: 8px;
	padding: 30px;
	margin-bottom: 30px;
}

.awcp-pets-rx-intro p {
	margin-bottom: 15px;
	color: #54595f;
	line-height: 1.6;
}

.awcp-pets-rx-intro p:last-child {
	margin-bottom: 0;
}

.awcp-rx-badge {
	display: inline-block;
	background: #d32f2f;
	color: #fff;
	padding: 2px 8px;
	border-radius: 4px;
	font-weight: 600;
	font-size: 12px;
}

.awcp-processing-time {
	font-weight: 600 !important;
}

.awcp-rx-products-section {
	margin-top: 30px;
}

.awcp-rx-products-section h3 {
	font-size: 20px;
	font-weight: 600;
	color: #2c3e50;
	margin-bottom: 25px;
}

/* RX Product Item */
.awcp-rx-product-item {
	border: 1px solid #c1cfb5;
	border-radius: 8px;
	padding: 20px;
	margin-bottom: 20px;
	background: #f8f8f7;
}

.awcp-rx-product-header {
	display: flex;
	gap: 20px;
	margin-bottom: 20px;
	padding-bottom: 20px;
	border-bottom: 1px solid #c1cfb5;
	align-items: center;
}

.awcp-rx-product-image {
	flex: 0 0 80px;
}

.awcp-rx-product-image img {
	width: 80px;
	height: 80px;
	object-fit: cover;
	border-radius: 4px;
}

.awcp-rx-product-details h4 {
	font-size: 16px;
	font-weight: 600;
	color: #2c3e50;
	margin-bottom: 0px;
}

.awcp-rx-product-meta {
	display: flex;
	gap: 20px;
	flex-wrap: wrap;
	font-size: 14px;
	color: #666;
}

.awcp-rx-requirement-notice {
	display: flex;
	align-items: center;
	gap: 10px;
	background: #fff;
	border: 1px solid #c1cfb5;
	border-radius: 6px;
	padding: 15px;
	margin-bottom: 20px;
}

.awcp-rx-icon {
	flex: 0 0 30px;
}

.awcp-rx-badge-icon {
	width: 30px;
	height: 30px;
}

.awcp-rx-text {
	color: #2c3e50;
	font-weight: 500;
}

/* Assignment Rows */
.awcp-rx-assignment-row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 30px;
	margin-top: 20px;
}

@media (max-width: 768px) {
	.awcp-rx-assignment-row {
		grid-template-columns: 1fr;
	}
}

.awcp-assignment-step {
	background: #fff;
	border: 1px solid #c1cfb5;
	border-radius: 8px;
	padding: 20px;
}

.awcp-step-label {
	display: block;
	margin-bottom: 15px;
	font-size: 14px;
	color: #666;
}

.awcp-step-label strong {
	color: #2c3e50;
	font-size: 15px;
}

.awcp-pet-select-wrapper,
.awcp-prescription-select-wrapper {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.awcp-pet-select,
.awcp-prescription-select {
	width: 100%;
	padding: 12px 15px;
	border: 1px solid #c1cfb5;
	border-radius: 4px;
	font-size: 14px;
}

.awcp-add-pet-button,
.awcp-upload-prescription-button {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 12px 20px;
	background: #9a9484;
	color: #fff;
	border: none;
	border-radius: 30px;
	font-weight: 600;
	cursor: pointer;
	transition: all 0.3s;
}

.awcp-add-pet-button:hover,
.awcp-upload-prescription-button:hover {
	background: #9a9484;
}

.awcp-add-pet-button:disabled,
.awcp-upload-prescription-button:disabled {
	background: #ddded8 !important;
	color: #9e9e9e;
	cursor: not-allowed;
	pointer-events: none !important;
}

.awcp-pet-icon {
	font-size: 18px;
	font-weight: 700;
}
/* ===== Delivery Step ===== */
.awcp-delivery-section.awcp-shipping-methods {
    background: #ddded8;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    margin-top: 20px;
}
.awcp-delivery-section.awcp-shipping-methods ul#shipping_method {
    list-style: none;
    padding-left: 0;
    margin-top: 10px;
}
.awcp-delivery-section.awcp-order-notes textarea#order_comments {
    padding: 20px !important;
    border-radius: 8px;
}
/* ===== Modal Styles ===== */
.awcp-modal {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 9999;
	display: none !important; /* Force hidden by default */
}

.awcp-modal[style*="display: block"],
.awcp-modal[style*="display:block"] {
	display: block !important; /* Force visible when shown */
}

.awcp-modal-overlay {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.6);
}

.awcp-modal-content {
	position: relative;
	background: #fff;
	max-width: 600px;
	margin: 50px auto;
	border-radius: 8px;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
	z-index: 10000;
	max-height: 90vh;
	overflow-y: auto;
}

.awcp-modal-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 20px 30px;
	border-bottom: 1px solid #c1cfb5;
}

.awcp-modal-header h3 {
	font-size: 20px;
	font-weight: 600;
	color: #2c3e50;
	margin: 0;
}

.awcp-modal-close {
	background: none;
	border: none;
	font-size: 30px;
	color: #757575;
	cursor: pointer;
	line-height: 1;
	padding: 0;
	width: 30px;
	height: 30px;
}

.awcp-modal-close:hover {
	color: #2c3e50;
}

.awcp-modal-body {
	padding: 30px;
}

.awcp-add-pet-visual {
	text-align: center;
	margin-bottom: 30px;
}

.awcp-pet-icons {
	max-width: 200px;
	margin-bottom: 15px;
}

.awcp-no-pets-message {
	color: #757575;
	font-size: 16px;
}

.awcp-modal-actions {
	display: flex;
	justify-content: flex-end;
	gap: 15px;
	margin-top: 30px;
}

/* ===== Step Actions ===== */
.awcp-step-actions {
	margin-top: 40px;
	padding-top: 30px;
	border-top: 1px solid #c1cfb5;
	text-align: right;
}

.awcp-continue-button {
	padding: 14px 40px !important;
	font-size: 16px !important;
	background: #9a9484 !important;
	color: #fff !important;
	border: none !important;
	border-radius: 30px !important;
	font-weight: 600 !important;
	cursor: pointer;
	transition: all 0.3s;
}

.awcp-continue-button:hover {
	background: #9a9484 !important;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
	/* Compact horizontal progress bar for mobile */
	.awcp-progress-bar {
		padding: 20px 15px;
	}
	
	.awcp-progress-steps {
		flex-direction: row; /* Keep horizontal */
		gap: 5px;
		max-width: 100%;
	}
	
	.awcp-progress-step {
		gap: 5px;
		flex: 1;
		min-width: 0; /* Allow flex items to shrink */
	}
	
	/* Smaller circles on mobile */
	.awcp-step-circle {
		width: 35px;
		height: 35px;
		font-size: 14px;
		border-width: 2px;
	}
	
	/* Smaller, wrapped labels */
	.awcp-step-label {
		font-size: 11px;
		text-align: center;
		line-height: 1.2;
		max-width: 80px;
		word-wrap: break-word;
		hyphens: auto;
	}
	
	/* Smaller arrows */
	.awcp-step-arrow {
		font-size: 14px;
		margin-top: -25px;
		flex: 0 0 15px;
	}
	
	/* Content padding */
	.awcp-multistep-content {
		padding: 20px 10px;
	}
	
	/* Auth buttons stack */
	.awcp-auth-buttons {
		flex-direction: column;
	}
	
	.awcp-auth-buttons .button,
	.awcp-auth-buttons .button-secondary {
		width: 100%;
	}
}

/* ===== Loading States ===== */
.awcp-loading {
	position: relative;
	opacity: 0.6;
	pointer-events: none;
}

.awcp-loading::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 30px;
	height: 30px;
	margin: -15px 0 0 -15px;
	border: 3px solid #f3f3f3;
	border-top: 3px solid #9a9484;
	border-radius: 50%;
	animation: awcp-spin 1s linear infinite;
}

@keyframes awcp-spin {
	0% { transform: rotate(0deg); }
	100% { transform: rotate(360deg); }
}

/* ===== Woo Notice Overrides ===== */
.woocommerce-notices-wrapper .woocommerce-message,
.woocommerce-notices-wrapper .woocommerce-error,
.woocommerce-notices-wrapper .woocommerce-info {
	margin-bottom: 20px;
}

/* ===== Payment Step Accordion Layout ===== */
.awcp-payment-wrapper {
	margin: 0 auto;
}

.awcp-payment-sections-accordion {
	margin-top: 30px;
}

.awcp-payment-accordion-section {
	background: #fff;
	border: 2px solid #c1cfb5;
	border-radius: 8px;
	margin-bottom: 20px;
	transition: all 0.3s ease;
}

.awcp-payment-accordion-section.awcp-section-active {
	border-color: #9a9484;
	box-shadow: 0 2px 12px rgba(61, 90, 254, 0.15);
}

.awcp-payment-accordion-section.awcp-section-completed {
	border-color: #61ce70;
	background: #f8fff9;
}

.awcp-section-header {
	padding: 20px 25px;
	cursor: pointer;
	display: flex;
	align-items: center;
	gap: 15px;
}

.awcp-section-radio {
	width: 20px;
	height: 20px;
	cursor: pointer;
	margin: 0;
}

.awcp-section-radio:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

.awcp-section-label {
	flex: 1;
	cursor: pointer;
	margin: 0;
	font-size: 16px;
	font-weight: 600;
	color: #2c3e50;
}

.awcp-section-completed .awcp-section-label {
	color: #61ce70;
}

.awcp-section-title {
	display: block;
}

.awcp-section-content {
	display: none;
	border-top: 1px solid #c1cfb5;
}

.awcp-section-inner {
	padding: 30px;
}

/* Order Review Table */
.awcp-section-inner .shop_table {
	width: 100%;
	border-collapse: collapse;
	margin-bottom: 25px;
	border: none !important;
}

.awcp-section-inner .shop_table th,
.awcp-section-inner .shop_table td {
	padding: 12px 15px;
	text-align: left;
	border-bottom: 1px solid #f0f0f0;
}
.shop_table {
	border-radius: 10px !important;
    overflow: hidden;
    outline: solid 3px #bebfba;
}

.awcp-section-inner .shop_table thead th {
	background: #f8f8f7;
	font-weight: 600;
	border-bottom: 3px solid #bebfba;
}

.awcp-section-inner .shop_table .product-name {
	font-weight: 500;
}

.awcp-section-inner .shop_table .product-name small {
	display: block;
	margin-top: 5px;
	font-size: 13px;
	color: #666;
	font-weight: normal;
}
.shop_table ul#shipping_method {
    list-style: none;
    padding-left: 0;
    margin-top: 10px;
}
.awcp-section-inner .shop_table tfoot th {
	font-weight: 600;
}

.awcp-section-inner .shop_table tfoot .order-total th,
.awcp-section-inner .shop_table tfoot .order-total td {
	font-size: 18px;
	font-weight: bold;
	/*color: #9a9484;*/
	padding-top: 15px;
	border-top: 3px solid #bebfba;
    background: #ddded8;
}

/* Billing Fields */
.woocommerce-billing-fields__field-wrapper .form-row, .woocommerce-shipping-fields__field-wrapper .form-row {
	margin-bottom: 5px;
	padding-bottom: 10px;
}

.woocommerce-billing-fields__field-wrapper label {
	font-weight: 500;
	margin-bottom: 5px;
	display: block;
	color: #2c3e50;
}

.woocommerce-billing-fields__field-wrapper input[type="text"],
.woocommerce-billing-fields__field-wrapper input[type="email"],
.woocommerce-billing-fields__field-wrapper input[type="tel"],
.woocommerce-billing-fields__field-wrapper select,
.woocommerce-billing-fields__field-wrapper textarea {
	width: 100%;
	padding: 12px 15px;
	border: 1px solid #c1cfb5;
	border-radius: 4px;
	font-size: 14px;
}

.woocommerce-billing-fields__field-wrapper input:focus,
.woocommerce-billing-fields__field-wrapper select:focus,
.woocommerce-billing-fields__field-wrapper textarea:focus {
	border-color: #9a9484;
	outline: none;
	box-shadow: 0 0 0 2px rgba(61, 90, 254, 0.1);
}

/* Payment Methods */
.wc_payment_methods {
	list-style: none;
	padding: 0;
	margin: 0 0 20px 0;
}

.wc_payment_method {
	margin-bottom: 15px;
	padding: 15px;
	background: #f8f8f7;
	border: 2px solid #c1cfb5;
	border-radius: 6px;
	transition: all 0.3s ease;
}

.wc_payment_method:hover {
	border-color: #9a9484;
	background: #f0f4ff;
}

.wc_payment_method label {
	font-weight: 600;
	cursor: pointer;
	display: flex;
	align-items: center;
	gap: 10px;
}

.payment_box {
	margin-top: 15px;
	border-top: none;
	border-radius: 10px !important;
    padding: 20px !important;
}

/* Section Navigation Buttons */
.awcp-section-actions {
	margin-top: 25px;
	display: flex;
	gap: 15px;
	/*justify-content: space-between;*/
	justify-content: flex-end;
	align-items: center;
}

.awcp-next-section,
.awcp-prev-section {
	padding: 12px 30px;
	font-size: 15px;
	font-weight: 600;
	border-radius: 30px;
	cursor: pointer;
	transition: all 0.3s ease;
	border: none;
}

.awcp-next-section {
	background: #9a9484;
	color: #fff;
}

.awcp-next-section:hover {
	background: #1e2870;
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(40, 53, 147, 0.3);
}

.awcp-prev-section {
	background: #f0f0f0;
	color: #2c3e50;
}

.awcp-prev-section:hover {
	background: #c1cfb5;
}

/* Place Order Button */
#place_order {
	padding: 15px 40px;
	font-size: 16px;
	font-weight: 600;
	background: #61ce70;
	color: #fff;
	border: none;
	border-radius: 30px;
	cursor: pointer;
	transition: all 0.3s ease;
	margin-left: 15px;
}

#place_order:hover {
	background: #45a049;
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}

#place_order:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

/* Terms & Conditions */
.woocommerce-terms-and-conditions-wrapper {
	padding: 15px;
	background: #f8f8f7;
	border-radius: 4px;
	margin-bottom: 20px;
}

.woocommerce-terms-and-conditions-wrapper label {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	cursor: pointer;
	font-weight: normal;
}

/* Form Row Styling */
.form-row.place-order {
	/*display: flex;*/
	align-items: center;
	justify-content: space-between;
	margin-top: 20px;
	padding-top: 20px;
	border-top: 1px solid #c1cfb5;
}

/* Responsive */
@media (max-width: 767px) {
	.awcp-section-inner {
		padding: 20px 15px;
	}
	
	.awcp-section-actions {
		flex-direction: column;
	}
	
	.awcp-next-section,
	.awcp-prev-section {
		width: 100%;
		text-align: center;
	}
	
	.form-row.place-order {
		flex-direction: column;
		gap: 15px;
	}
	
	#place_order {
		width: 100%;
		margin-left: 0;
	}
	
	/* CRITICAL: Prevent table horizontal overflow */
	.awcp-section-inner .shop_table {
		display: block;
		width: 100%;
		overflow-x: auto;
		-webkit-overflow-scrolling: touch;
	}
	
	.awcp-section-inner .shop_table thead {
		display: none; /* Hide table headers on mobile */
	}
	
	.awcp-section-inner .shop_table tbody,
	.awcp-section-inner .shop_table tr,
	.awcp-section-inner .shop_table td {
		display: block;
		width: 100%;
	}
	
	.awcp-section-inner .shop_table tr {
		margin-bottom: 15px;
		border: 1px solid #e0e0e0;
		border-radius: 8px;
		padding: 10px;
		background: #fff;
	}
	
	.awcp-section-inner .shop_table td {
		padding: 8px 5px;
		text-align: left;
		border: none;
		position: relative;
		padding-left: 45%;
		min-height: 30px;
	}
	
	/* Add labels for mobile */
	.awcp-section-inner .shop_table td:before {
		content: attr(data-title);
		position: absolute;
		left: 10px;
		width: 40%;
		padding-right: 10px;
		font-weight: 600;
		text-align: left;
		color: #333;
	}
	
	/* Product name needs special handling */
	.awcp-section-inner .shop_table td.product-name {
		padding-left: 10px;
		font-size: 14px;
		font-weight: 600;
		margin-bottom: 5px;
	}
	
	.awcp-section-inner .shop_table td.product-name:before {
		display: none;
	}
	
	/* Subtotal/Total styling */
	.awcp-section-inner .shop_table td.product-total {
		text-align: right;
		padding-right: 10px;
		font-weight: 600;
	}
	
	/* Footer (totals) styling */
	.awcp-section-inner .shop_table tfoot {
		display: block;
	}
	
	.awcp-section-inner .shop_table tfoot tr {
		display: flex;
		justify-content: space-between;
		padding: 10px;
		margin-bottom: 5px;
		border: none;
		border-radius: 0;
	}
	
	.awcp-section-inner .shop_table tfoot th,
	.awcp-section-inner .shop_table tfoot td {
		display: inline-block;
		width: auto;
		padding: 5px;
		position: static;
		border: none;
	}
	
	.awcp-section-inner .shop_table tfoot th:before,
	.awcp-section-inner .shop_table tfoot td:before {
		display: none;
	}
	
	.awcp-section-inner .shop_table tfoot .order-total {
		background: #f8f8f7;
		border-radius: 8px;
		font-size: 16px;
	}
	
	/* Smaller text for mobile */
	.awcp-section-inner .shop_table th,
	.awcp-section-inner .shop_table td {
		font-size: 13px;
	}
}

/* ===== Inline Display for Product Variations ===== */
/* Transform WooCommerce's default stacked <dl> variation display into inline format */
.awcp-payment-wrapper .woocommerce-checkout-review-order-table .product-name dl.variation,
.awcp-payment-wrapper .shop_table .product-name dl.variation {
	display: block !important; /* Force onto new line below product name */
	margin: 5px 0 0 0;
	padding: 0;
	font-size: 13px;
	color: #666;
}

/* Display dt and dd inline within the block */
.awcp-payment-wrapper .shop_table .product-name dl.variation dt,
.awcp-payment-wrapper .shop_table .product-name dl.variation dd {
	display: inline;
	margin: 0;
	padding: 0;
}

/* Hide the p tags inside dd but keep their content */
.awcp-payment-wrapper .shop_table .product-name dl.variation dd p {
	display: inline;
	margin: 0;
	padding: 0;
}

/* Add pipe separator after each dd (except the last one) */
.awcp-payment-wrapper .shop_table .product-name dl.variation dd:not(:last-of-type)::after {
	content: " | ";
	color: #666;
}

/* Make dt (labels) bold */
.awcp-payment-wrapper .shop_table .product-name dl.variation dt {
	font-weight: bold;
}

/* Add space after dt before the value */
.awcp-payment-wrapper .shop_table .product-name dl.variation dt::after {
	content: " ";
}



/* ===== Select Dropdown Styling ===== */
.awcp-select-group {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.awcp-select-group label {
	font-size: 15px;
	font-weight: 600;
	color: #2c3e50;
	display: block;
}

.awcp-select-group select.awcp-drug-class-select {
	width: 100%;
	padding: 12px 15px;
	font-size: 14px;
	font-weight: 500;
	color: #2c3e50;
	background: #f8f9fa;
	border: 2px solid #e0e0e0;
	border-radius: 8px;
	cursor: pointer;
	transition: all 0.2s ease;
	appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath fill='%232c3e50' d='M0 0l6 8 6-8z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 15px center;
	padding-right: 45px;
}

.awcp-select-group select.awcp-drug-class-select:hover {
	background-color: #e8f4f8;
	border-color: #9a9484;
}

.awcp-select-group select.awcp-drug-class-select:focus {
	outline: none;
	border-color: #c1cfb5;
	background-color: #fff;
}

/* ===== Text Input Styling ===== */
.awcp-text-group {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.awcp-text-group label {
	font-size: 15px;
	font-weight: 600;
	color: #2c3e50;
	display: block;
}

.awcp-text-group input.awcp-drug-class-text {
	width: 100%;
	padding: 12px 15px;
	font-size: 14px;
	font-weight: 500;
	color: #2c3e50;
	background: #f8f9fa;
	border: 2px solid #e0e0e0;
	border-radius: 8px;
	transition: all 0.2s ease;
}

.awcp-text-group input.awcp-drug-class-text:hover {
	background-color: #e8f4f8;
	border-color: #9a9484;
}

.awcp-text-group input.awcp-drug-class-text:focus {
	outline: none;
	border-color: #c1cfb5;
	background-color: #fff;
}

.awcp-text-group input.awcp-drug-class-text::placeholder {
	color: #a0a0a0;
	font-weight: 400;
}

/* ===== Species Validation Error ===== */
.awcp-species-error.awcp-validation-error {
	background: #fef8f8;
	border-left: 4px solid #d63638;
	padding: 15px;
	margin: 0 0 20px 0; width: 100%;
	animation: slideDown 0.3s ease;
	border-radius: 4px;
}

.awcp-species-error.awcp-validation-error h4 {
	margin: 0 0 10px 0;
	color: #d63638;
	font-size: 16px;
	font-weight: 600;
}

.awcp-species-error.awcp-validation-error p {
	padding-bottom: 0;
	margin: 0 !important;
	color: #50575e;
	line-height: 1.5;
}

.awcp-species-error.awcp-validation-error p + p {
	margin-top: 5px !important;
}

.awcp-species-error.awcp-validation-error p:last-child {
	margin-top: 10px !important;
	font-weight: 600;
}

.awcp-species-error .dashicons {
	font-size: 20px;
	vertical-align: middle;
}

@keyframes slideDown {
	from {
		opacity: 0;
		transform: translateY(-10px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

	.awcp-sticky-alert {
		left: 10px;
		right: 10px;
		max-width: none;
	}
}

	.awcp-sticky-alert {
		left: 10px;
		right: 10px;
		max-width: none;
	}
}

/* ===== Updated Sticky Alerts with Header and Better Layout ===== */
.awcp-sticky-alert-header {
	display: flex;
	justify-content: flex-end;
	padding: 8px 12px 0;
}

.awcp-sticky-alert-header .awcp-dismiss-sticky {
	background: transparent;
	border: none;
	color: #d63638;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
	padding: 0;
	margin: 0;
	font-weight: 300;
}

.awcp-sticky-alert-header .awcp-dismiss-sticky:hover {
	color: #a61919;
}

.awcp-sticky-alert .awcp-sticky-alert-content {
	padding: 0 15px 12px;
}

.awcp-sticky-alert-text button.awcp-scroll-to-error {
	display: inline-block;
	margin-top: 8px;
	padding: 4px 12px;
	background: #d63638;
	color: white;
	border: none;
	border-radius: 4px;
	font-size: 12px;
	font-weight: 600;
	cursor: pointer;
	text-decoration: none;
}

.awcp-sticky-alert-text button.awcp-scroll-to-error:hover {
	background: #a61919;
}

/* Remove old button styles that conflict */
.awcp-sticky-alert .awcp-scroll-to-error:not(button),
.awcp-sticky-alert .awcp-dismiss-sticky:not(.awcp-sticky-alert-header .awcp-dismiss-sticky) {
	display: none;
}

/* ===== Sticky Species Alerts (Always Visible, Stacked) ===== */
.awcp-sticky-alert {
	position: fixed;
	right: 20px;
	z-index: 99999;
	border-radius: 8px;
	box-shadow: 0 4px 12px rgba(0,0,0,0.15);
	max-width: 350px;
	animation: slideInRight 0.3s ease;
	transition: top 0.3s ease;
	border: 2px solid;
}

/* RED styling for errors */
.awcp-sticky-error {
	background: #fef8f8;
	border-color: #d63638;
}

.awcp-sticky-error .dashicons {
	color: #d63638;
}

.awcp-sticky-error .awcp-dismiss-sticky {
	color: #d63638;
}

.awcp-sticky-error .awcp-dismiss-sticky:hover {
	background: rgba(214, 54, 56, 0.1);
}

/* YELLOW styling for warnings */
.awcp-sticky-warning {
	background: #fcf9e8;
	border-color: #dba617;
}

.awcp-sticky-warning .dashicons {
	color: #dba617;
}

.awcp-sticky-warning .awcp-dismiss-sticky {
	color: #dba617;
}

.awcp-sticky-warning .awcp-dismiss-sticky:hover {
	background: rgba(219, 166, 23, 0.1);
}

/* Close button in top right */
.awcp-dismiss-sticky {
	position: absolute;
	top: 8px;
	right: 8px;
	background: transparent;
	border: none;
	color: #d63638;
	font-size: 24px;
	line-height: 1;
	padding: 4px;
	cursor: pointer;
	border-radius: 4px;
	font-weight: 300;
	width: 28px;
	height: 28px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.awcp-dismiss-sticky:hover {
	background: rgba(214, 54, 56, 0.1);
}

/* Content area */
.awcp-sticky-alert-content {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	padding: 15px;
}

.awcp-sticky-alert .awcp-sticky-alert-content {
	padding: 15px;
	padding-right: 45px; /* Extra space for X button in top right */
}

.awcp-sticky-alert .dashicons {
	color: #d63638;
	font-size: 24px;
	flex-shrink: 0;
	margin-top: 2px;
}

/* Text area */
.awcp-sticky-alert-text {
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.awcp-sticky-alert-text strong {
	color: #d63638;
	font-weight: 600;
	font-size: 14px;
	line-height: 1.3;
}

.awcp-alert-message {
	color: #50575e;
	font-size: 13px;
	line-height: 1.4;
}

/* View Details button */
.awcp-scroll-to-error {
	background: transparent;
	border: none;
	color: #d63638;
	font-size: 12px;
	font-weight: 600;
	padding: 0;
	cursor: pointer;
	text-align: left;
	text-decoration: underline;
}

.awcp-scroll-to-error:hover {
	color: #b52629;
	text-decoration: none;
}

/* Animation */
@keyframes slideInRight {
	from {
		opacity: 0;
		transform: translateX(50px);
	}
	to {
		opacity: 1;
		transform: translateX(0);
	}
}

/* Mobile responsive */
@media (max-width: 768px) {
	.awcp-sticky-alert {
		left: 10px;

/* Extra padding on sticky content for X button */
.awcp-sticky-alert .awcp-sticky-alert-content {
    padding-right: 45px; /* Space for X button */
}

/* Close button for main error/warning boxes */
.awcp-validation-error .awcp-dismiss-main-error,
.awcp-validation-warning .awcp-dismiss-main-error {
    position: absolute;
    top: 15px;
    right: 15px;
    background: transparent;
    border: none;
    color: #d63638;
    font-size: 24px;
    line-height: 1;
    padding: 4px;
    cursor: pointer;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 300;
}

.awcp-validation-error .awcp-dismiss-main-error:hover,
.awcp-validation-warning .awcp-dismiss-main-error:hover {
    opacity: 0.7;
}

/* Make validation boxes relative for absolute positioning of X */
.awcp-validation-error,
.awcp-validation-warning {
    position: relative;
    padding-right: 45px; /* Space for X button */
}

}

.awcp-sticky-warning .awcp-scroll-to-error:hover {
    color: #94660c;
}

/* WooCommerce Notice Styles for Auth Forms */
.awcp-auth-default-form .woocommerce-notices-wrapper,
.awcp-auth-container .woocommerce-notices-wrapper {
	margin-bottom: 20px;
}

.awcp-auth-default-form .woocommerce-message,
.awcp-auth-default-form .woocommerce-error,
.awcp-auth-default-form .woocommerce-info,
.awcp-auth-container .woocommerce-message,
.awcp-auth-container .woocommerce-error,
.awcp-auth-container .woocommerce-info {
	padding: 15px 20px;
	margin-bottom: 15px;
	border-radius: 4px;
	border-left: 4px solid;
	background: #fff;
	box-shadow: 0 1px 3px rgba(0,0,0,0.1);
	list-style: none;
	font-size: 14px;
	line-height: 1.5;
}

.awcp-auth-default-form .woocommerce-error,
.awcp-auth-container .woocommerce-error {
	border-left-color: #d63638;
	background: #fef8f8;
	color: #50575e;
}

.awcp-auth-default-form .woocommerce-error::before,
.awcp-auth-container .woocommerce-error::before {
	content: "⚠️ ";
	font-size: 16px;
	margin-right: 5px;
}

.awcp-auth-default-form .woocommerce-message,
.awcp-auth-container .woocommerce-message {
	border-left-color: #2f855a;
	background: #d5f4e6;
	color: #1e4034;
}

.awcp-auth-default-form .woocommerce-message::before,
.awcp-auth-container .woocommerce-message::before {
	content: "✓ ";
	font-size: 16px;
	margin-right: 5px;
}

.awcp-auth-default-form .woocommerce-info,
.awcp-auth-container .woocommerce-info {
	border-left-color: #007cba;
	background: #f0f6fc;
	color: #2c3338;
}

.awcp-auth-default-form .woocommerce-info::before,
.awcp-auth-container .woocommerce-info::before {
	content: "ℹ️ ";
	font-size: 16px;
	margin-right: 5px;
}

/* Remove list bullets if notices are in a list */
.awcp-auth-default-form ul.woocommerce-error,
.awcp-auth-default-form ul.woocommerce-message,
.awcp-auth-default-form ul.woocommerce-info,
.awcp-auth-container ul.woocommerce-error,
.awcp-auth-container ul.woocommerce-message,
.awcp-auth-container ul.woocommerce-info {
	padding-left: 20px;
}

.awcp-auth-default-form ul.woocommerce-error li,
.awcp-auth-default-form ul.woocommerce-message li,
.awcp-auth-default-form ul.woocommerce-info li,
.awcp-auth-container ul.woocommerce-error li,
.awcp-auth-container ul.woocommerce-message li,
.awcp-auth-container ul.woocommerce-info li {
	list-style: none;
	margin: 0;
	padding: 0;
}
