:root {
  --primary-color: #2563eb;
  --primary-hover: #1d4ed8;
  --bg-color: #f3f4f6;
  --card-bg: #ffffff;
  --text-main: #1f2937;
  --text-muted: #6b7280;
  --border-color: #e5e7eb;
  --success-color: #059669;
}

.calculator-wrapper {
  background: var(--card-bg);
  width: 100%;
  border-radius: 16px;
  box-shadow:
    0 4px 6px -1px rgba(0, 0, 0, 0.1),
    0 2px 4px -1px rgba(0, 0, 0, 0.06);
  padding: 2rem;
  margin: auto;
}

.calculator-wrapper header {
  text-align: center;
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 1rem;
}

p.subtitle {
  color: var(--text-muted);
  margin: 0;
}

.calc-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 768px) {
  .calc-grid {
    grid-template-columns: 1.5fr 1fr;
  }
}

/* Form Section */
.calc-grid .form-section {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.calc-grid .input-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.calc-grid .input-group label {
  font-weight: 600;
  font-size: 0.95rem;
}

.calc-grid select,
.calc-grid input[type="range"] {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-size: 1rem;
  background-color: #fff;
  transition: border-color 0.2s;
}

.calc-grid select:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* Range Slider Styling */
.calc-grid .range-container {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.calc-grid .range-value {
  min-width: 80px;
  text-align: center;
  font-weight: bold;
  color: var(--primary-color);
  background: #eff6ff;
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
}

/* Checkbox Grid */
.calc-grid .features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1rem;
  align-content: start;
  grid-auto-rows: min-content;
}

.calc-grid .feature-card {
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 0.75rem;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  user-select: none;
  height: fit-content;
}

.calc-grid .feature-card:hover {
  border-color: var(--primary-color);
  background-color: #eff6ff;
}

.calc-grid .feature-card input {
  accent-color: var(--primary-color);
  width: 18px;
  height: 18px;
}

/* Summary Section (Sticky Sidebar on Desktop) */
.summary-section {
  background-color: #f8fafc;
  border-radius: 12px;
  padding: 1.5rem;
  border: 1px solid var(--border-color);
  height: fit-content;
  position: sticky;
  top: 20px;
}

.summary-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-main);
}

.summary-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.summary-row.total {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 2px dashed var(--border-color);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-main);
  align-items: center;
}

.total-amount {
  color: var(--primary-color);
}

.cta-button {
  display: block;
  width: 100%;
  background-color: var(--primary-color);
  color: white;
  text-align: center;
  padding: 1rem;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  margin-top: 1.5rem;
  transition: background-color 0.2s;
  border: none;
  cursor: pointer;
  font-size: 1rem;
}

.cta-button:hover {
  background-color: var(--primary-hover);
}

.note {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: 1rem;
}

/* Quote Form Layout */
.form-row {
  display: flex;
  gap: 20px;
  margin-bottom: 20px;
  width: 100%;
}

.form-row .input-group {
  flex: 1;
  min-width: 0;
}

@media (max-width: 600px) {
  .form-row {
    flex-direction: column;
    gap: 15px;
  }
}
