:root {
  --primary: #1a73e8;
  --primary-dark: #0d47a1;
  --secondary: #00c853;
  --dark: #202124;
  --light: #f8f9fa;
  --gray: #5f6368;
  --warning: #ff6d00;
  --uber: #1fbad6;
  --app99: #ff6600;
  --error: #f5938a;
  --safe: #34a853;
  --warning-light: #fbbc05;
}

@keyframes pulse {
  0% {
    opacity: 1;
  }

  50% {
    opacity: 0.7;
  }

  100% {
    opacity: 1;
  }
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Inter, Helvetica, Arial, sans-serif;
}

body {
  background-color: #f0f2f5;
  color: var(--dark);
  line-height: 1.6;
}

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

.btn {
  padding: 10px 20px;
  border-radius: 50px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-primary {
  background-color: var(--secondary);
  color: white;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.calculator-container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
  margin-bottom: 40px;
}

@media (min-width: 992px) {
  .calculator-container {
    grid-template-columns: 1fr 1fr;
  }
}

.input-section,
.results-section {
  background-color: white;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  padding: 30px;
}

.section-title {
  font-size: 1.5rem;
  margin-bottom: 25px;
  padding-bottom: 15px;
  border-bottom: 2px solid var(--primary);
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.input-group {
  margin-bottom: 20px;
}

.input-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  color: var(--gray);
}

.input-group input,
.input-group select {
  width: 100%;
  padding: 14px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 1rem;
  transition: border 0.3s;
}

.input-group input:focus,
.input-group select:focus {
  border-color: var(--primary);
  outline: none;
  box-shadow: 0 0 0 2px rgba(26, 115, 232, 0.2);
}

.slider-container {
  position: relative;
  padding-top: 25px;
}

.slider-value {
  position: absolute;
  top: 0;
  right: 0;
  font-weight: 600;
  color: var(--primary);
}

input[type="range"] {
  width: 100%;
  height: 8px;
  -webkit-appearance: none;
  background: #e0e0e0;
  border-radius: 10px;
  outline: none;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  background: var(--primary);
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s;
}

input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.2);
  background: var(--primary-dark);
}

.checkbox-group {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}

.checkbox-group input {
  margin-right: 10px;
  width: 18px;
  height: 18px;
}

.results-card {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  border-radius: 15px;
  padding: 25px;
  margin-bottom: 25px;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.results-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 15px;
  font-size: 1.3rem;
}

.results-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

.result-item {
  background-color: rgba(255, 255, 255, 0.15);
  padding: 15px;
  border-radius: 10px;
}

.result-label {
  font-size: 0.9rem;
  opacity: 0.85;
  margin-bottom: 5px;
}

.result-value {
  font-size: 1.5rem;
  font-weight: 700;
  transition: color 0.3s ease;
}

.highlight {
  color: var(--secondary);
  font-weight: 700;
}

.highlight-update {
  color: var(--primary);
  animation: pulse 1.5s;
}

.summary {
  margin-top: 25px;
}

.summary-item {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid #eee;
}

.summary-item:last-child {
  border-bottom: none;
  font-weight: 700;
  font-size: 1.1rem;
  padding-top: 15px;
}

.tco-details {
  margin-top: 20px;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 15px;
}

.tco-details-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  font-weight: 600;
  color: var(--primary);
}

.tco-details-header:hover {
  color: var(--primary-dark);
}

.tco-details-content {
  margin-top: 15px;
  padding-top: 15px;
  border-top: 1px solid #eee;
}

.tco-detail-item {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
  transition: all 0.3s ease;
}

.tco-detail-item.updated {
  background-color: rgba(0, 150, 255, 0.1);
  transform: scale(1.01);
}

.tco-detail-item.total {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid #ddd;
  font-weight: 600;
}

.detail-label {
  color: #666;
}

.info-section {
  background-color: white;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  padding: 30px;
  margin-bottom: 40px;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 25px;
  margin-top: 25px;
}

.info-card {
  border-left: 4px solid var(--primary);
  padding: 15px 20px;
  background-color: #f8f9fa;
  border-radius: 0 8px 8px 0;
}

.info-card h4 {
  margin-bottom: 10px;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.ad-space {
  background-color: white;
  border-radius: 10px;
  height: 120px;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 30px 0;
  font-style: italic;
  color: var(--gray);
  border: 1px dashed #ddd;
}

.advanced-btn {
  margin-top: 15px;
  background: none;
  border: none;
  color: var(--primary);
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
}

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  display: none;
}

.modal {
  background: white;
  border-radius: 15px;
  width: 90%;
  max-width: 800px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 30px;
  position: relative;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--gray);
}

.tco-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.tco-item {
  border: 1px solid #eee;
  border-radius: 10px;
  padding: 15px;
}

.tco-item h4 {
  margin-bottom: 10px;
  color: var(--primary);
}

.tco-item input {
  width: 100%;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 5px;
  margin-top: 5px;
}

.vehicle-option {
  display: none;
}

.city-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 15px 0;
}

.city-btn {
  padding: 8px 15px;
  border-radius: 20px;
  background: #eee;
  border: none;
  cursor: pointer;
  transition: all 0.3s;
}

.city-btn.active {
  background: var(--primary);
  color: white;
}

.app-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 15px 0;
}

.app-btn {
  padding: 10px 20px;
  border-radius: 8px;
  border: 2px solid #ddd;
  background: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  transition: all 0.3s;
}

.app-btn.active {
  border-color: var(--uber);
  background: rgba(31, 186, 214, 0.1);
}

.app-btn.app99.active {
  border-color: var(--app99);
  background: rgba(255, 102, 0, 0.1);
}

.app-icon {
  font-size: 1.2rem;
}

.uber-icon {
  color: var(--uber);
}

.app99-icon {
  color: var(--app99);
}

.finance-input {
  display: none;
  margin-top: 15px;
  padding: 15px;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 3px solid var(--primary);
}

.finance-input input {
  margin-top: 5px;
}

.error-message {
  color: var(--error);
  font-weight: 600;
  margin-top: 10px;
  padding: 10px;
  border-radius: 8px;
  background-color: rgba(234, 67, 53, 0.1);
  display: none;
}

.negative-value {
  color: var(--error);
  font-weight: 700;
}

.tco-summary {
  margin-top: 20px;
  padding: 15px;
  background-color: #f0f7ff;
  border-radius: 8px;
  border-left: 3px solid var(--primary);
}

.tco-summary h4 {
  margin-bottom: 10px;
  color: var(--primary);
}

.tco-summary-item {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
}

.hours-safe {
  color: var(--safe);
  font-weight: 600;
}

.hours-warning {
  color: var(--warning-light);
  font-weight: 600;
}

.hours-danger {
  color: var(--error);
  font-weight: 600;
}

.km-safe {
  color: var(--safe);
}

.km-warning {
  color: var(--warning-light);
}

.km-danger {
  color: var(--error);
}

.calc-mode-selector {
  display: flex;
  gap: 10px;
  margin: 15px 0;
}

.mode-btn {
  padding: 10px 15px;
  border-radius: 20px;
  background: #eee;
  border: none;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.3s;
}

.mode-btn.active {
  background: var(--primary);
  color: white;
}

.clt-comparison {
  background-color: #f8f9fa;
  border-radius: 10px;
  padding: 20px;
  margin-top: 25px;
  border-left: 4px solid #1a73e8;
}

.benefit-item {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}

.benefit-item.highlight {
  color: #1a73e8;
  font-weight: 600;
}

.benefit-item.total {
  border-top: 1px solid #e2e8f0;
  padding-top: 10px;
  font-weight: 600;
}

.clt-comparison h3 {
  color: var(--primary);
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.clt-result {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 10px 0;
  color: var(--dark);
}

.clt-details {
  margin-top: 15px;
  padding: 10px;
  background-color: rgba(0, 0, 0, 0.05);
  border-radius: 8px;
  font-size: 0.9rem;
  color: var(--gray);
}

.work-comparison {
  margin-top: 25px;
  padding: 15px;
  background: #f0f7ff;
  border-radius: 8px;
}

.comparison-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 15px;
}

.comparison-item {
  text-align: center;
  padding: 15px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.comparison-item h5 {
  color: #5f6368;
  margin-bottom: 10px;
}

.disabled-field {
  opacity: 0.5;
  pointer-events: none;
}

.energy-fields {
  display: none;
  margin-top: 15px;
  padding: 10px;
  background: #f0f7ff;
  border-radius: 8px;
  border-left: 3px solid var(--primary);
}

.clt-benefit {
  display: flex;
  justify-content: space-between;
  margin: 8px 0;
}
