* {
  margin: 0;
  padding: 0;
}

body {
  background: #f1f2f3;
}

.container {
  box-sizing: border-box;
  width: 100%;
  max-width: 1640px;
  min-width: 1240px;
  margin: 25px auto;
  color: #333;
}

.container  *{
  box-sizing: border-box;
}

header {
  margin-bottom: 25px;
  text-align: center;
}

h1 {
  font-size: 2.1rem;
  margin-bottom: 5px;
}

.subtitle {
  font-size: 1rem;
  opacity: 0.9;
  max-width: 90%;
  margin: 0 auto;
  line-height: 1.6;
}

.calculator {
  background: white;
  border-radius: 16px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
  padding: 20px;
  margin-bottom: 25px;
}

.input-section {
  display: flex;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 30px;
}

.input-group {
  flex: 1;
}

.input-group label {
  display: block;
  margin-bottom: 12px;
  font-weight: 600;
  font-size: 1.1rem;
  color: #2c3e50;
}

.input-field {
  width: 100%;
  padding: 15px 20px;
  font-size: 1.2rem;
  border: 2px solid #e0e0e0;
  border-radius: 12px;
  transition: all 0.3s ease;
}

.input-field:focus {
  border-color: #3498db;
  outline: none;
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
}

.buttons {
  display: flex;
  justify-content: center;
  gap: 30px;
  margin-bottom: 30px;
}

.btn {
  padding: 14px 50px;
  font-size: 1.1rem;
  font-weight: 600;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-primary {
  background: linear-gradient(135deg, #3498db, #2980b9);
  color: white;
}

.btn-secondary {
  background: linear-gradient(135deg, #2ecc71, #27ae60);
  color: white;
}

.btn-reset {
  background: linear-gradient(135deg, #e74c3c, #c0392b);
  color: white;
}

.btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
}

.btn:active {
  transform: translateY(0);
}

.results {
  background: #f8f9fa;
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  border: 1px solid #eee;
}

.results-title {
  font-size: 1.5rem;
  margin-bottom: 25px;
  color: #2c3e50;
  text-align: left;
}

.results-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
}

.result-card {
  background: white;
  border-radius: 12px;
  padding: 25px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease;
}

.result-card.rgb {
  border-top: 4px solid #3498db;
}

.result-card.pentile {
  border-top: 4px solid #e74c3c;
}

.result-title {
  font-size: 1.2rem;
  margin-bottom: 15px;
  color: #7f8c8d;
}

.result-value {
  font-size: 3.2rem;
  font-weight: 700;
  color: #2c3e50;
}

.result-unit {
  font-size: 1.2rem;
  color: #7f8c8d;
  margin-left: 5px;
}

.result-description {
  margin-top: 15px;
  color: #7f8c8d;
  font-size: 1rem;
  line-height: 1.5;
}

.info-section {
  background: white;
  border-radius: 16px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
  padding: 20px;
  margin-bottom: 25px;
}

.section-title {
  font-size: 1.5rem;
  margin-bottom: 25px;
  color: #2c3e50;
  display: flex;
  align-items: center;
  gap: 10px;
}

.info-content {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
}

.info-card {
  padding: 20px;
  border-radius: 12px;
  background: #f8f9fa;
  border: 1px solid #eee;
}

.info-card h3 {
  margin-bottom: 15px;
  color: #2c3e50;
  display: flex;
  align-items: center;
  gap: 10px;
}

.info-card p {
  margin-bottom: 10px;
  color: #555;
}

footer {
  text-align: center;
  color: #7f8c8d;
}

.highlight {
  color: #e74c3c;
  font-weight: 600;
}

.definition {
  background: linear-gradient(135deg, #f1c40f, #f39c12);
  color: white;
  padding: 4px 8px;
  border-radius: 6px;
  display: inline-block;
}
