/*** GENERAL ***/
/* buttons */
/* Table Styling  */
.analysis_table{
  width:100%;
  border-collapse:collapse;
}
.analysis_table td {
  padding:6px;
  border:1px solid #eee;
}


  .waomrt-form-wrapper {
	width: 100%;
	/* max-width: 900px; */
	background: white;
	border-radius: 16px;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
	overflow: hidden;
}

/* Header */
.waomrt-header {
	background:#667eea;
	color: white;
	padding: 3rem 2rem;
	text-align: center;
	position: relative;
}

.waomrt-icon-wrapper {
	width: 80px;
	height: 80px;
	background: rgba(255, 255, 255, 0.2);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0 auto 1.5rem;
	backdrop-filter: blur(10px);
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.waomrt-icon-wrapper svg {
	width: 40px;
	height: 40px;
	color: white;
}

.waomrt-title {
	font-size: 2.5rem;
	font-weight: 700;
	margin: 0 0 0.5rem 0;
	text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.waomrt-subtitle {
	font-size: 1.125rem;
	opacity: 0.95;
	margin: 0;
	font-weight: 300;
}

/* Form */
.opterra-market-form {
	padding: 2.5rem 2rem;
}

.waomrt-form-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 2rem;
	margin-bottom: 2rem;
}

/* Form Group */
.waomrt-form-group {
	display: flex;
	flex-direction: column;
}

.waomrt-label {
	font-size: 0.875rem;
	font-weight: 600;
	color: #1f2937;
	margin-bottom: 0.5rem;
	display: flex;
	align-items: center;
	gap: 0.25rem;
}

.waomrt-required {
	color: #ef4444;
	font-weight: 700;
}

/* Input Wrapper */
.waomrt-input-wrapper {
	position: relative;
	display: flex;
	align-items: center;
}

.waomrt-select-icon {
	position: absolute;
	left: 1rem;
	width: 20px;
	height: 30px;
	color: #6b7280;
	pointer-events: none;
	z-index: 1;
}

.waomrt-select-icon svg {
	width: 100%;
	height: 100%;
}

/* Select and Input Styles */
.waomrt-select,
.waomrt-input {
	width: 100%;
	padding: 0.1rem 0rem 0.1rem 3rem;
	border: 1px solid #aaa;
	border-radius: 4px;
	font-size: 1rem;
	color: #1f2937;
	background-color: #ffffff;
	transition: all 0.3s ease;
	font-family: inherit;
}

.waomrt-select {
	appearance: none;
	cursor: pointer;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 1rem center;
	background-size: 20px;
	padding-right: 3rem;
}

.waomrt-input {
	cursor: text;
}

.waomrt-select:hover,
.waomrt-input:hover {
	border-color: #667eea;
}

.waomrt-select:focus,
.waomrt-input:focus {
	outline: none;
	border-color: #667eea;
	box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
	background-color: #ffffff;
}

.waomrt-select option {
	padding: 0.5rem;
}

/* Help Text */
.waomrt-help-text {
	font-size: 0.813rem;
	color: #6b7280;
	margin-top: 0.5rem;
	margin-bottom: 0;
	font-style: italic;
}

/* Form Actions */
.waomrt-form-actions {
	display: flex;
	gap: 1rem;
	padding-top: 1rem;
	border-top: 2px solid #f3f4f6;
}
span#select2-opterra_state-container, 
span#select2-opterra_naics-container, 
span#select2-opterra_county-container,
span#select2-opterra_service_kob-container,
span#select2-opterra_msa-container,
input#opterra_year{
    padding-left: 44px;
}

.button-primary {
	flex: 1;
	background:#c36!important;
	color: white!important;
	border: none;
	padding: 1rem 2rem;
	border-radius: 8px;
	font-size: 1rem;
	font-weight: 600;
	cursor: pointer;
	transition: all 0.3s ease;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
	font-family: inherit;
}

.button-primary:hover {
	transform: translateY(-2px);
	box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.button-primary:active {
	transform: translateY(0);
}

.button-primary.waomrt-loading {
	opacity: 0.7;
	cursor: not-allowed;
}

.waomrt-button-icon {
	width: 20px;
	height: 20px;
}

.waomrt-spinner {
	width: 20px;
	height: 20px;
	border: 2px solid rgba(255, 255, 255, 0.3);
	border-top: 2px solid white;
	border-radius: 50%;
	animation: waomrt-spin 1s linear infinite;
	display: none;
}

.button-primary.waomrt-loading .waomrt-spinner {
	display: block;
}

.button-primary.waomrt-loading .waomrt-button-icon {
	display: none;
}

.waomrt-reset-button {
	background: #f3f4f6;
	color: #4b5563;
	border: 2px solid #e5e7eb;
	padding: 1rem 2rem;
	border-radius: 8px;
	font-size: 1rem;
	font-weight: 600;
	cursor: pointer;
	transition: all 0.3s ease;
	font-family: inherit;
}

.waomrt-reset-button:hover {
	background: #e5e7eb;
	border-color: #d1d5db;
}

/* Footer */
.waomrt-footer {
	padding: 2rem;
	background: #f9fafb;
	border-top: 2px solid #e5e7eb;
}

.waomrt-info-card {
	background: white;
	padding: 1.5rem;
	border-radius: 8px;
	border-left: 4px solid #667eea;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.waomrt-info-title {
	font-size: 1.125rem;
	font-weight: 600;
	color: #1f2937;
	margin: 0 0 0.75rem 0;
}

.waomrt-info-text {
	font-size: 0.875rem;
	color: #6b7280;
	line-height: 1.6;
	margin: 0;
}

.year-select {
	padding: 0rem 1rem 0rem 3rem;
	border-radius: 4px;
}
/* added */
.card {
    background: #fff;
    border: 1px solid #ccd0d4;
    border-radius: 4px;
    padding: 20px;
    margin-bottom: 20px;
}

.card h2 {
    margin-top: 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

#import-progress {
    background: #f9f9f9;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.widefat td {
    padding: 10px;
}

.dashicons {
    margin-right: 5px;
}

.select2-container--default .select2-selection--single .select2-selection__clear{
	padding-top: 0px;
	padding-bottom: 0px;
}
.select2-container--default .select2-selection--single .select2-selection__clear:hover{
	color: red;
}

/* Animations */
@keyframes waomrt-spin {
	0% {
		transform: rotate(0deg);
	}
	100% {
		transform: rotate(360deg);
	}
}
@media (min-width: 768px) {
    .waomrt-form-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Responsive Design */
@media (min-width: 768px) and (max-width: 1024px) { 
	.waomrt-form-grid {
		grid-template-columns: repeat(2, 1fr);
	}
	/* added  */
	.waomrt-label{
		font-size: 0.715rem;
	}
	.waomrt-help-text{
		font-size: 0.620rem;
	}
	.select2-container--default .select2-selection--single .select2-selection__rendered{
		font-size: 0.715rem;
		white-space: nowrap;
		overflow: hidden;
		text-overflow: ellipsis;
		max-width: 260px;
	}
	.select2-results__option--selectable{
		font-size: 0.715rem;
	}
	.opterra-results .opterra-card .analysis_table thead th{
		font-size: 12px;
	}
	.opterra-results .opterra-card .analysis_table tbody tr td{
		font-size: 11px;
	}
	.fallback-log-table tbody tr td {
		font-size: 12px;
	}
	
}

@media (max-width: 767px) {
	.waomrt-title {
		font-size: 1.75rem;
	}

	.waomrt-select,
	.waomrt-input {
		/* padding: 0.75rem 0.875rem 0.75rem 2.75rem; */
		font-size: 0.938rem;
	}

	.waomrt-select-icon {
		left: 0.875rem;
		width: 18px;
		height: 26px;
	}
	.waomrt-form-grid {
		gap: 1.25rem;
	}
	.opterra-card{
		padding: 8px !important;
	}
	/* This removes the Notes column on mobile layout  */
	/* table th:nth-child(5),
    table td:nth-child(5) {
        display: none;
    } */
	.waomrt-label{
		font-size: 0.715rem;
	}
	.waomrt-help-text{
		font-size: 0.620rem;
	}
	.select2-container--default .select2-selection--single .select2-selection__rendered{
		font-size: 0.715rem;
		white-space: nowrap;
		overflow: hidden;
		text-overflow: ellipsis;
		max-width: 260px;
	}
	.select2-results__option--selectable{
		font-size: 0.715rem;
	}
	.opterra-results .opterra-card .analysis_table thead th{
		font-size: 12px;
	}
	.opterra-results .opterra-card .analysis_table tbody tr td{
		font-size: 11px;
	}
	.fallback-log-table tbody tr td {
		font-size: 12px;
	}
	
}

/* Validation Styles */
.waomrt-select:invalid,
.waomrt-input:invalid {
	border-color: #ef4444;
}

.waomrt-select:valid,
.waomrt-input:valid {
	border-color: #10b981;
}

/* Accessibility */
/* .waomrt-select:focus-visible,
.waomrt-input:focus-visible {
	outline: 2px solid #667eea;
	outline-offset: 2px;
} */

/* Custom styling for select options */
.waomrt-select option:disabled {
	color: #9ca3af;
}
select#opterra_msa , input#opterra_year{
    padding-top: 1px;
    padding-bottom: 1px;
    border-radius: 4px;
}

/* added new */
.fallback-log-table {
    font-size: 0.9rem;
}

.fallback-log-table thead th {
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
}

.fallback-log-table tbody tr {
    vertical-align: middle;
}

.fallback-log-table .badge {
    font-size: 0.75rem;
    padding: 0.35em 0.65em;
}

.fallback-log-table small {
    display: block;
    line-height: 1.6;
}

.opterra-fallback-log h3 {
    color: #2c3e50;
    font-size: 1.25rem;
    font-weight: 600;
    border-bottom: 2px solid #3498db;
    padding-bottom: 8px;
}