/**
 * FlexLease Calculator - Public Styles
 *
 * Frontend styling for the FlexLease Calculator with Wolf Packing brand colors.
 *
 * @package FlexLease_Calculator
 * @since 1.0.0
 */

/* ==========================================================================
   Variables & Reset
   ========================================================================== */

:root {
	--flexlease-primary: #0a1857;
	--flexlease-secondary: #fbd846;
	--flexlease-white: #ffffff;
	--flexlease-light-bg: #f8f9fa;
	--flexlease-border: #e0e0e0;
	--flexlease-text-dark: #333333;
	--flexlease-text-light: #666666;
	--flexlease-success: #4caf50;
	--flexlease-shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
	--flexlease-shadow-md: 0 4px 15px rgba(0, 0, 0, 0.1);
	--flexlease-shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.1);
	--flexlease-radius-sm: 8px;
	--flexlease-radius-md: 12px;
	--flexlease-radius-lg: 20px;
}

.flexlease-calculator-wrapper * {
	box-sizing: border-box;
}

/* ==========================================================================
   Main Container
   ========================================================================== */

.flexlease-calculator-wrapper {
	width: 100%;
	background: linear-gradient(135deg, var(--flexlease-primary) 0%, #162a5e 100%);
	padding: 40px 20px;
	margin: 0 auto;
	font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.flexlease-container {
	max-width: 1200px;
	margin: 0 auto;
}

/* ==========================================================================
   Header Section
   ========================================================================== */

.flexlease-header {
	text-align: center;
	color: var(--flexlease-white);
	margin-bottom: 40px;
	animation: flexleaseFadeInDown 0.8s ease-out;
}

.flexlease-header h1 {
	font-size: 2.5rem;
	margin: 0 0 10px 0;
	font-weight: 700;
	text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
	color: var(--flexlease-white);
}

.flexlease-subtitle {
	font-size: 1.2rem;
	margin: 0 0 20px 0;
	opacity: 0.9;
	color: var(--flexlease-white);
}

.flexlease-feature-badges {
	display: flex;
	justify-content: center;
	gap: 20px;
	flex-wrap: wrap;
	margin-top: 20px;
}

.flexlease-badge {
	background: rgba(255, 255, 255, 0.2);
	backdrop-filter: blur(10px);
	padding: 10px 20px;
	border-radius: 25px;
	color: var(--flexlease-white);
	font-size: 0.9rem;
	font-weight: 500;
	box-shadow: var(--flexlease-shadow-sm);
}

/* ==========================================================================
   Calculator Grid
   ========================================================================== */

.flexlease-calculator-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 30px;
	animation: flexleaseFadeInUp 0.8s ease-out;
}

@media (max-width: 968px) {
	.flexlease-calculator-grid {
		grid-template-columns: 1fr;
	}
}

/* ==========================================================================
   Panels
   ========================================================================== */

.flexlease-calculator-panel,
.flexlease-results-panel {
	background: var(--flexlease-white);
	border-radius: var(--flexlease-radius-lg);
	padding: 40px;
	box-shadow: var(--flexlease-shadow-lg);
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.flexlease-calculator-panel:hover,
.flexlease-results-panel:hover {
	transform: translateY(-5px);
	box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
}

.flexlease-calculator-panel h2,
.flexlease-results-panel h2 {
	color: var(--flexlease-primary);
	margin: 0 0 25px 0;
	font-size: 1.8rem;
	font-weight: 700;
}

/* ==========================================================================
   Form Elements
   ========================================================================== */

.flexlease-form-group {
	margin-bottom: 25px;
}

.flexlease-form-group label {
	display: block;
	margin-bottom: 8px;
	font-weight: 600;
	color: var(--flexlease-text-dark);
	font-size: 0.95rem;
}

.flexlease-form-group input[type="number"],
.flexlease-form-group select {
	width: 100%;
	padding: 12px 15px;
	border: 2px solid var(--flexlease-border);
	border-radius: var(--flexlease-radius-sm);
	font-size: 1rem;
	transition: all 0.3s ease;
	font-family: inherit;
	color: var(--flexlease-text-dark);
}

.flexlease-form-group input[type="number"]:focus,
.flexlease-form-group select:focus {
	outline: none;
	border-color: var(--flexlease-primary);
	box-shadow: 0 0 0 3px rgba(10, 24, 87, 0.1);
}

/* ==========================================================================
   Lease Terms Selection
   ========================================================================== */

.flexlease-lease-terms {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 15px;
	margin-bottom: 15px;
}

.flexlease-term-option {
	text-align: center;
	padding: 20px;
	border: 2px solid var(--flexlease-border);
	border-radius: var(--flexlease-radius-md);
	cursor: pointer;
	transition: all 0.3s ease;
	position: relative;
	overflow: hidden;
	background: var(--flexlease-white);
}

.flexlease-term-option:hover {
	border-color: var(--flexlease-primary);
	transform: translateY(-2px);
}

.flexlease-term-option.flexlease-term-selected {
	border-color: var(--flexlease-primary);
	background: linear-gradient(135deg, #f0f4ff 0%, #e6edff 100%);
}

.flexlease-term-option.flexlease-term-selected::after {
	content: '✓';
	position: absolute;
	top: 10px;
	right: 10px;
	background: var(--flexlease-primary);
	color: var(--flexlease-white);
	width: 24px;
	height: 24px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 14px;
	font-weight: bold;
}

.flexlease-term-option h3 {
	font-size: 1.5rem;
	color: var(--flexlease-primary);
	margin: 0 0 5px 0;
	font-weight: 700;
}

.flexlease-term-option p {
	font-size: 0.85rem;
	color: var(--flexlease-text-light);
	margin: 0;
}

.flexlease-term-rate {
	font-weight: 600 !important;
	color: var(--flexlease-primary) !important;
	margin-top: 5px !important;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.flexlease-calculate-btn {
	width: 100%;
	padding: 15px;
	background: linear-gradient(135deg, var(--flexlease-primary) 0%, #162a5e 100%);
	color: var(--flexlease-white);
	border: none;
	border-radius: var(--flexlease-radius-md);
	font-size: 1.1rem;
	font-weight: 600;
	cursor: pointer;
	transition: all 0.3s ease;
	box-shadow: 0 4px 15px rgba(10, 24, 87, 0.3);
	font-family: inherit;
}

.flexlease-calculate-btn:hover {
	transform: translateY(-2px);
	box-shadow: 0 6px 20px rgba(10, 24, 87, 0.4);
}

.flexlease-calculate-btn:active {
	transform: translateY(0);
}

/* ==========================================================================
   Results Display
   ========================================================================== */

.flexlease-result-item {
	padding: 20px;
	background: linear-gradient(135deg, var(--flexlease-light-bg) 0%, #f0f2f5 100%);
	border-radius: var(--flexlease-radius-md);
	margin-bottom: 15px;
	transition: all 0.3s ease;
}

.flexlease-result-item:hover {
	transform: translateX(5px);
	box-shadow: -5px 0 20px rgba(0, 0, 0, 0.1);
}

.flexlease-result-label {
	font-size: 0.9rem;
	color: var(--flexlease-text-light);
	margin-bottom: 5px;
}

.flexlease-result-value {
	font-size: 2rem;
	font-weight: 700;
	color: var(--flexlease-primary);
	margin: 0;
}

/* ==========================================================================
   Tax Savings Highlight
   ========================================================================== */

.flexlease-savings-highlight {
	background: linear-gradient(135deg, var(--flexlease-success) 0%, #45a049 100%);
	color: var(--flexlease-white);
	padding: 20px;
	border-radius: var(--flexlease-radius-md);
	text-align: center;
	margin-top: 20px;
	animation: flexleasePulse 2s infinite;
}

.flexlease-savings-highlight h3 {
	margin: 0 0 10px 0;
	font-size: 1.2rem;
	color: var(--flexlease-white);
}

.flexlease-tax-savings-value {
	font-size: 1.5rem;
	font-weight: 700;
	margin: 10px 0;
}

.flexlease-tax-disclaimer {
	font-size: 0.9rem;
	margin: 10px 0 0 0;
	opacity: 0.9;
}

/* ==========================================================================
   Comparison Table
   ========================================================================== */

.flexlease-comparison-chart {
	margin-top: 30px;
	overflow-x: auto;
}

.flexlease-comparison-chart h3 {
	margin-bottom: 15px;
	color: var(--flexlease-primary);
	font-size: 1.2rem;
}

.flexlease-comparison-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.95rem;
}

.flexlease-comparison-table th,
.flexlease-comparison-table td {
	padding: 12px;
	text-align: left;
	border-bottom: 1px solid var(--flexlease-border);
}

.flexlease-comparison-table th {
	background: var(--flexlease-light-bg);
	font-weight: 600;
	color: var(--flexlease-text-dark);
}

.flexlease-comparison-table tr:hover {
	background: #f9f9f9;
}

.flexlease-comparison-table .flexlease-advantage {
	color: var(--flexlease-success);
	font-weight: 600;
}

/* ==========================================================================
   CTA Section
   ========================================================================== */

.flexlease-cta-section {
	margin-top: 30px;
	padding: 30px;
	background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%);
	border-radius: var(--flexlease-radius-md);
	text-align: center;
}

.flexlease-cta-section h3 {
	color: var(--flexlease-primary);
	margin: 0 0 15px 0;
	font-size: 1.3rem;
}

.flexlease-cta-section p {
	color: var(--flexlease-text-dark);
	margin-bottom: 10px;
}

.flexlease-cta-section ul {
	text-align: left;
	margin: 15px 0;
	padding-left: 20px;
	color: var(--flexlease-text-light);
	line-height: 1.8;
}

.flexlease-email-form {
	display: flex;
	gap: 10px;
	margin-top: 20px;
}

.flexlease-email-input {
	flex: 1;
	padding: 12px 15px;
	border: 2px solid var(--flexlease-secondary);
	border-radius: var(--flexlease-radius-sm);
	font-size: 1rem;
	font-family: inherit;
}

.flexlease-email-input:focus {
	outline: none;
	border-color: var(--flexlease-primary);
	box-shadow: 0 0 0 3px rgba(10, 24, 87, 0.1);
}

.flexlease-email-submit {
	padding: 12px 25px;
	background: var(--flexlease-secondary);
	color: var(--flexlease-primary);
	border: none;
	border-radius: var(--flexlease-radius-sm);
	font-weight: 600;
	cursor: pointer;
	transition: all 0.3s ease;
	font-family: inherit;
	font-size: 1rem;
}

.flexlease-email-submit:hover {
	transform: translateY(-2px);
	box-shadow: 0 4px 15px rgba(251, 216, 70, 0.4);
}

/* ==========================================================================
   Empty State
   ========================================================================== */

.flexlease-empty-state {
	text-align: center;
	padding: 60px 20px;
}

.flexlease-empty-state p {
	color: var(--flexlease-text-light);
	font-size: 1.1rem;
	margin: 0;
}

/* ==========================================================================
   Modal
   ========================================================================== */

.flexlease-modal {
	display: none;
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.5);
	z-index: 9999;
	animation: flexleaseFadeIn 0.3s ease;
}

.flexlease-modal-content {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	background: var(--flexlease-white);
	padding: 40px;
	border-radius: var(--flexlease-radius-lg);
	max-width: 500px;
	width: 90%;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
	animation: flexleaseSlideIn 0.3s ease;
}

.flexlease-modal-content h2 {
	color: var(--flexlease-success);
	margin: 0 0 20px 0;
	font-size: 1.8rem;
}

.flexlease-modal-content p {
	margin-bottom: 20px;
	color: var(--flexlease-text-dark);
	line-height: 1.6;
}

.flexlease-modal-subtitle {
	font-weight: 600 !important;
	color: var(--flexlease-primary) !important;
}

.flexlease-modal-content ul {
	text-align: left;
	margin: 15px 0;
	padding-left: 20px;
	color: var(--flexlease-text-light);
	line-height: 1.8;
}

.flexlease-btn-close {
	margin-top: 20px;
	padding: 10px 30px;
	background: var(--flexlease-primary);
	color: var(--flexlease-white);
	border: none;
	border-radius: var(--flexlease-radius-sm);
	cursor: pointer;
	font-family: inherit;
	font-size: 1rem;
	font-weight: 600;
	transition: all 0.3s ease;
}

.flexlease-btn-close:hover {
	background: #162a5e;
	transform: translateY(-2px);
}

/* ==========================================================================
   Animations
   ========================================================================== */

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

@keyframes flexleaseFadeInUp {
	from {
		opacity: 0;
		transform: translateY(30px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@keyframes flexleaseFadeIn {
	from {
		opacity: 0;
	}
	to {
		opacity: 1;
	}
}

@keyframes flexleaseSlideIn {
	from {
		transform: translate(-50%, -50%) scale(0.9);
		opacity: 0;
	}
	to {
		transform: translate(-50%, -50%) scale(1);
		opacity: 1;
	}
}

@keyframes flexleasePulse {
	0% {
		transform: scale(1);
	}
	50% {
		transform: scale(1.02);
	}
	100% {
		transform: scale(1);
	}
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 768px) {
	.flexlease-calculator-wrapper {
		padding: 20px 10px;
	}

	.flexlease-header h1 {
		font-size: 1.8rem;
	}

	.flexlease-subtitle {
		font-size: 1rem;
	}

	.flexlease-calculator-panel,
	.flexlease-results-panel {
		padding: 25px;
	}

	.flexlease-lease-terms {
		grid-template-columns: 1fr;
		gap: 10px;
	}

	.flexlease-feature-badges {
		gap: 10px;
	}

	.flexlease-badge {
		font-size: 0.8rem;
		padding: 8px 15px;
	}

	.flexlease-email-form {
		flex-direction: column;
	}

	.flexlease-result-value {
		font-size: 1.5rem;
	}

	.flexlease-modal-content {
		padding: 25px;
	}
}

@media (max-width: 480px) {
	.flexlease-header h1 {
		font-size: 1.5rem;
	}

	.flexlease-calculator-panel h2,
	.flexlease-results-panel h2 {
		font-size: 1.3rem;
	}

	.flexlease-comparison-table {
		font-size: 0.85rem;
	}

	.flexlease-comparison-table th,
	.flexlease-comparison-table td {
		padding: 8px;
	}
}
