html {
  height: -webkit-fill-available;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, sans-serif;
  background: linear-gradient(135deg, #e3f2fd, #e8f5e9);
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

.app {
  width: 100%;
  max-width: 420px;
  padding: 20px;
}

.screen {
  display: none;
  background: white;
  padding: 28px;
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
  animation: fadeIn 0.4s ease;
}

.screen.active {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
h1 {
  margin-bottom: 20px;
  text-align: center;
  font-weight: 600;
}

.description-box {
  background: #f3f6f9;
  padding: 15px;
  border-radius: 12px;
  margin-bottom: 22px;
  font-size: 14px;
  line-height: 1.7;
}
.description-box .formula {
  font-weight: bold;
  text-align: center;
  margin-top: 12px;
}

.form-group {
  margin-bottom: 18px;
}
.form-group label {
  display: block;
  font-size: 13px;
  margin-bottom: 6px;
  color: #666;
}
.form-group input {
  width: 100%;
  padding: 12px;
  font-size: 16px;
  border-radius: 10px;
  border: 1px solid #ddd;
  transition: 0.2s;
}
.form-group input:focus {
  outline: none;
  border-color: #4CAF50;
  box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.2);
}

button {
  cursor: pointer;
  transition: 0.2s;
}

.main-btn {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, #4CAF50, #2e7d32);
  color: white;
  border: none;
  border-radius: 12px;
  font-size: 16px;
  font-weight: bold;
}
.main-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}
.main-btn:active {
  transform: scale(0.98);
}

.sub-btn {
  width: 100%;
  padding: 14px;
  background: #555;
  color: white;
  border: none;
  border-radius: 12px;
  font-size: 15px;
}
.sub-btn:hover {
  opacity: 0.9;
}

.result-box {
  text-align: center;
  margin: 40px 0;
}
.result-box h1 {
  font-size: 36px;
  background: linear-gradient(135deg, #4CAF50, #2e7d32);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}