/* Down Payment (Wkład Własny) Calculator Styles */

/* Hero */
.wkw-hero {
  background: linear-gradient(135deg, #1E3A5F 0%, #1E88E5 50%, #059669 100%);
  color: white;
  padding: 80px 0 60px;
  text-align: center;
}

.wkw-hero h1 {
  font-size: 2.6rem;
  font-weight: 900;
  margin-bottom: 20px;
  line-height: 1.2;
}

.wkw-hero .lead {
  font-size: 1.15rem;
  opacity: 0.92;
  margin-bottom: 32px;
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
}

.wkw-hero-badges {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 0;
}

.wkw-hero-badge {
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 24px;
  padding: 8px 18px;
  font-size: 0.9rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* Calculator Section */
.wkw-calculator-section {
  padding: 48px 0;
  background: #f8faff;
}

/* Calculator Card */
.wkw-card {
  background: white;
  border-radius: 24px;
  padding: 2.5rem;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.wkw-card-header {
  text-align: center;
  margin-bottom: 2rem;
}

.wkw-card-title {
  font-size: 1.4rem;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 0.25rem;
}

.wkw-card-subtitle {
  color: #6b7280;
  font-size: 0.9rem;
}

/* Form Groups */
.wkw-form-group {
  margin-bottom: 1.75rem;
}

.wkw-form-label {
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.5rem;
  display: block;
  font-size: 0.95rem;
}

.wkw-form-input {
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  padding: 14px 16px;
  font-size: 1rem;
  transition: all 0.3s ease;
  background: white;
  width: 100%;
  font-family: 'Inter', sans-serif;
}

.wkw-form-input:focus {
  outline: none;
  border-color: #059669;
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.1);
  transform: translateY(-1px);
}

.wkw-form-hint {
  font-size: 0.82rem;
  color: #9ca3af;
  margin-top: 4px;
}

.wkw-value-display {
  font-size: 0.95rem;
  font-weight: 700;
  color: #059669;
  text-align: right;
  min-width: 120px;
}

.wkw-slider-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.wkw-slider-row input[type="range"] {
  flex: 1;
}

/* Custom Range Slider */
input[type="range"].wkw-range {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: #e5e7eb;
  outline: none;
  margin: 8px 0;
}

input[type="range"].wkw-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: linear-gradient(135deg, #059669, #1E88E5);
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(5, 150, 105, 0.4);
  transition: transform 0.15s ease;
}

input[type="range"].wkw-range::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

input[type="range"].wkw-range::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: linear-gradient(135deg, #059669, #1E88E5);
  cursor: pointer;
  border: none;
  box-shadow: 0 2px 8px rgba(5, 150, 105, 0.4);
}

/* Section Divider */
.wkw-section-label {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6b7280;
  margin-bottom: 16px;
  margin-top: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid #e5e7eb;
}

/* Percent Selector */
.wkw-percent-selector {
  display: flex;
  gap: 0;
  border-radius: 12px;
  overflow: hidden;
  border: 2px solid #e5e7eb;
  margin-bottom: 1.75rem;
}

.wkw-percent-option {
  flex: 1;
  padding: 14px 8px;
  text-align: center;
  cursor: pointer;
  font-weight: 700;
  font-size: 1rem;
  color: #6b7280;
  background: white;
  border: none;
  border-right: 1px solid #e5e7eb;
  transition: all 0.2s ease;
  position: relative;
  font-family: 'Inter', sans-serif;
}

.wkw-percent-option:last-child {
  border-right: none;
}

.wkw-percent-option:hover {
  background: #f0fdf4;
  color: #059669;
}

.wkw-percent-option.active {
  background: linear-gradient(135deg, #059669, #1E88E5);
  color: white;
}

.wkw-percent-option .wkw-recommended {
  display: block;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-top: 2px;
  opacity: 0.75;
}

.wkw-percent-option.active .wkw-recommended {
  opacity: 1;
}

/* Primary Button */
.btn-wkw-primary {
  background: linear-gradient(135deg, #059669, #1E88E5);
  color: white;
  border: none;
  border-radius: 12px;
  padding: 16px 32px;
  font-weight: 700;
  font-size: 1.05rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  transition: all 0.3s ease;
  font-family: 'Inter', sans-serif;
}

.btn-wkw-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(5, 150, 105, 0.3);
}

/* Disclaimer */
.wkw-disclaimer {
  background: #fff8e1;
  border: 1px solid #ffd54f;
  border-radius: 10px;
  padding: 14px 18px;
  font-size: 0.82rem;
  color: #5d4037;
  margin-top: 24px;
  line-height: 1.6;
}

/* Result Card */
.wkw-result-card {
  background: white;
  border-radius: 16px;
  padding: 32px;
  text-align: center;
  border: 2px solid #e5e7eb;
  margin-top: 24px;
}

/* Decision Indicator */
.wkw-decision {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-bottom: 24px;
  padding: 16px 20px;
  border-radius: 12px;
}

.wkw-decision-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.wkw-decision-text {
  font-weight: 700;
  font-size: 1rem;
  text-align: left;
}

.wkw-decision-green {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
}

.wkw-decision-green .wkw-decision-icon {
  background: #059669;
  color: white;
}

.wkw-decision-green .wkw-decision-text {
  color: #065f46;
}

.wkw-decision-yellow {
  background: #fffbeb;
  border: 1px solid #fde68a;
}

.wkw-decision-yellow .wkw-decision-icon {
  background: #d97706;
  color: white;
}

.wkw-decision-yellow .wkw-decision-text {
  color: #92400e;
}

.wkw-decision-red {
  background: #fef2f2;
  border: 1px solid #fecaca;
}

.wkw-decision-red .wkw-decision-icon {
  background: #dc2626;
  color: white;
}

.wkw-decision-red .wkw-decision-text {
  color: #991b1b;
}

/* Result Stats */
.wkw-result-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid #f1f5f9;
}

.wkw-result-stat-value {
  font-size: 1.15rem;
  font-weight: 800;
  color: #1E3A5F;
}

.wkw-result-stat-value.savings {
  color: #059669;
}

.wkw-result-stat-value.warning {
  color: #d97706;
}

.wkw-result-stat-label {
  font-size: 0.76rem;
  color: #94a3b8;
  margin-top: 2px;
}

/* Progress Bar */
.wkw-progress {
  margin: 24px 0 8px;
}

.wkw-progress-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 8px;
  display: flex;
  justify-content: space-between;
}

.wkw-progress-bar {
  height: 28px;
  border-radius: 14px;
  background: #e5e7eb;
  overflow: hidden;
  position: relative;
}

.wkw-progress-fill {
  height: 100%;
  border-radius: 14px;
  background: linear-gradient(90deg, #059669, #34d399);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: white;
  min-width: 40px;
  transition: width 0.5s ease;
}

.wkw-progress-fill.complete {
  background: linear-gradient(90deg, #059669, #10b981);
}

/* Savings Timeline */
.wkw-timeline {
  margin: 24px 0 8px;
}

.wkw-timeline-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 8px;
}

.wkw-timeline-bar {
  display: flex;
  height: 32px;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
}

.wkw-timeline-segment {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  transition: width 0.5s ease;
  min-width: 2px;
}

.wkw-timeline-saved {
  background: linear-gradient(90deg, #059669, #34d399);
  color: white;
}

.wkw-timeline-remaining {
  background: linear-gradient(90deg, #93c5fd, #60a5fa);
  color: #1e3a8a;
}

.wkw-timeline-milestones {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  font-size: 0.72rem;
  color: #94a3b8;
  font-weight: 600;
}

/* Warning Box */
.wkw-warning-box {
  background: rgba(234, 88, 12, 0.06);
  border: 1px solid #fed7aa;
  border-left: 3px solid #ea580c;
  border-radius: 0 10px 10px 0;
  padding: 16px 20px;
  margin-top: 20px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.88rem;
  color: #9a3412;
  line-height: 1.6;
}

.wkw-warning-icon {
  flex-shrink: 0;
  color: #ea580c;
  margin-top: 2px;
}

/* Already Enough Box */
.wkw-success-box {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  border-left: 3px solid #059669;
  border-radius: 0 10px 10px 0;
  padding: 16px 20px;
  margin-top: 20px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.88rem;
  color: #065f46;
  line-height: 1.6;
}

/* Comparison Table */
.wkw-comparison-section {
  margin-top: 32px;
}

.wkw-comparison-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #1E3A5F;
  margin-bottom: 16px;
  text-align: center;
}

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

.wkw-comparison-table thead th {
  background: #1E3A5F;
  color: white;
  padding: 12px 14px;
  font-weight: 700;
  text-align: center;
  font-size: 0.82rem;
}

.wkw-comparison-table thead th:first-child {
  border-radius: 8px 0 0 0;
  text-align: left;
}

.wkw-comparison-table thead th:last-child {
  border-radius: 0 8px 0 0;
}

.wkw-comparison-table tbody td {
  padding: 12px 14px;
  border-bottom: 1px solid #e5e7eb;
  text-align: center;
  color: #374151;
}

.wkw-comparison-table tbody td:first-child {
  text-align: left;
  font-weight: 600;
}

.wkw-comparison-table tbody tr:nth-child(even) {
  background: #f8faff;
}

.wkw-comparison-table tbody tr.active-row {
  background: rgba(5, 150, 105, 0.08);
  border: 2px solid #059669;
}

.wkw-comparison-table tbody tr.active-row td {
  font-weight: 700;
}

.wkw-comparison-table .insurance-cost {
  color: #ea580c;
  font-weight: 600;
}

.wkw-comparison-table .no-insurance {
  color: #059669;
  font-weight: 600;
}

/* Save & Compare */
.wkw-save-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 20px;
}

.btn-wkw-secondary {
  padding: 10px 20px;
  border: 2px solid #e5e7eb;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  background: white;
  color: #64748b;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
  font-family: 'Inter', sans-serif;
}

.btn-wkw-secondary:hover {
  border-color: #059669;
  color: #059669;
}

/* Saved results grid */
.wkw-compare-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.wkw-compare-card {
  background: #f8faff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 16px;
  text-align: center;
  position: relative;
}

.wkw-compare-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  background: none;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  padding: 2px;
  font-size: 1rem;
  line-height: 1;
}

.wkw-compare-remove:hover {
  color: #dc2626;
}

.wkw-compare-big {
  font-size: 1.6rem;
  font-weight: 900;
  margin-bottom: 2px;
  color: #1E3A5F;
}

.wkw-compare-sub {
  font-size: 0.78rem;
  color: #94a3b8;
  font-weight: 600;
  margin-bottom: 8px;
}

.wkw-compare-detail {
  font-size: 0.82rem;
  color: #64748b;
  margin-bottom: 2px;
}

/* Educational Section */
.wkw-edu-section {
  padding: 64px 0;
  background: white;
}

.wkw-edu-section h2 {
  font-size: 1.8rem;
  font-weight: 800;
  color: #1E3A5F;
  margin-bottom: 16px;
}

.wkw-edu-section p {
  color: #555;
  font-size: 0.98rem;
  line-height: 1.8;
  margin-bottom: 16px;
}

.wkw-edu-definition {
  background: linear-gradient(135deg, #ecfdf5 0%, #f0f7ff 100%);
  border-left: 4px solid #059669;
  border-radius: 0 12px 12px 0;
  padding: 20px 24px;
  margin: 20px 0 32px;
  font-size: 1.02rem;
  line-height: 1.8;
  color: #1E3A5F;
}

/* Sources table */
.wkw-source-table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0 32px;
  font-size: 0.92rem;
}

.wkw-source-table thead th {
  background: #1E3A5F;
  color: white;
  padding: 12px 16px;
  font-weight: 700;
  text-align: left;
}

.wkw-source-table thead th:first-child {
  border-radius: 8px 0 0 0;
}

.wkw-source-table thead th:last-child {
  border-radius: 0 8px 0 0;
}

.wkw-source-table tbody td {
  padding: 12px 16px;
  border-bottom: 1px solid #e5e7eb;
  color: #374151;
}

.wkw-source-table tbody tr:nth-child(even) {
  background: #f8faff;
}

/* Checklist */
.wkw-checklist {
  list-style: none;
  padding: 0;
  margin: 16px 0 32px;
}

.wkw-checklist li {
  padding: 8px 0;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
  color: #374151;
}

.wkw-check-icon {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 0.75rem;
  font-weight: 800;
}

.wkw-check-icon.yes {
  background: #ecfdf5;
  color: #059669;
}

.wkw-check-icon.no {
  background: #fef2f2;
  color: #dc2626;
}

/* Steps */
.wkw-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin: 24px 0 0;
}

.wkw-step-card {
  background: #f8faff;
  border-radius: 16px;
  padding: 24px;
  text-align: center;
}

.wkw-step-num {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #059669, #1E88E5);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.2rem;
  margin: 0 auto 12px;
}

.wkw-step-card h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #1E3A5F;
  margin-bottom: 8px;
}

.wkw-step-card p {
  color: #64748b;
  font-size: 0.88rem;
  margin: 0;
}

/* FAQ Section */
.wkw-faq-section {
  background: #f8faff;
  padding: 64px 0;
}

.wkw-faq-section h2 {
  font-size: 2rem;
  font-weight: 800;
  color: #1E3A5F;
  text-align: center;
  margin-bottom: 12px;
}

.wkw-faq-lead {
  text-align: center;
  color: #64748b;
  font-size: 1.05rem;
  margin-bottom: 40px;
}

.wkw-faq-item {
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  margin-bottom: 12px;
  overflow: hidden;
  background: white;
}

.wkw-faq-question {
  padding: 18px 24px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #1E3A5F;
  font-size: 0.95rem;
  transition: background 0.15s;
}

.wkw-faq-question:hover {
  background: #ecfdf5;
}

.wkw-faq-answer {
  padding: 0 24px 0;
  color: #555;
  font-size: 0.93rem;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  line-height: 1.7;
}

.wkw-faq-answer.open {
  max-height: 1000px;
  padding: 0 24px 18px;
}

.wkw-faq-chevron {
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.wkw-faq-question.active .wkw-faq-chevron {
  transform: rotate(180deg);
}

/* CTA Section */
.wkw-final-cta {
  background: linear-gradient(135deg, #1E3A5F 0%, #1E88E5 50%, #059669 100%);
  color: white;
  padding: 64px 0;
  text-align: center;
}

.wkw-final-cta h2 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 16px;
}

.wkw-final-cta p {
  font-size: 1.1rem;
  opacity: 0.9;
  margin-bottom: 28px;
}

.wkw-cta-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn-wkw-cta-white {
  background: white;
  color: #059669;
  border: none;
  border-radius: 10px;
  padding: 16px 28px;
  font-weight: 800;
  font-size: 1rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-wkw-cta-white:hover {
  background: #f0fdf4;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
  color: #059669;
}

.btn-wkw-cta-outline {
  background: transparent;
  color: white;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-radius: 10px;
  padding: 14px 28px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-wkw-cta-outline:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: white;
  color: white;
  transform: translateY(-2px);
}

/* Responsive */
@media (max-width: 991px) {
  .wkw-card {
    padding: 1.5rem;
  }

  .wkw-result-stats {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 767px) {
  .wkw-hero h1 {
    font-size: 1.9rem;
  }

  .wkw-hero .lead {
    font-size: 1rem;
  }

  .wkw-result-stats {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .wkw-steps {
    grid-template-columns: 1fr;
  }

  .wkw-compare-grid {
    grid-template-columns: 1fr;
  }

  .wkw-decision {
    flex-direction: column;
    text-align: center;
  }

  .wkw-decision-text {
    text-align: center;
  }

  .wkw-cta-buttons {
    flex-direction: column;
    align-items: center;
  }

  .wkw-percent-selector {
    flex-wrap: wrap;
  }

  .wkw-percent-option {
    flex: 1 1 30%;
  }

  .wkw-comparison-table {
    font-size: 0.78rem;
  }

  .wkw-comparison-table thead th,
  .wkw-comparison-table tbody td {
    padding: 8px 6px;
  }
}

@media (max-width: 480px) {
  .wkw-hero h1 {
    font-size: 1.6rem;
  }
}

/* Toast notification */
.wkw-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  z-index: 10000;
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease;
  pointer-events: none;
}

.wkw-toast-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.wkw-toast-content {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #1e293b;
  color: #fff;
  padding: 14px 24px;
  border-radius: 12px;
  font-size: 0.95rem;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
  max-width: 440px;
}
