* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

body {
  background: white;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
  color: #333;
  line-height: 1.6;
}

ul {
  padding: 0 20px;
}

.container {
  width: 100%;
  max-width: 900px;
  background: rgba(255, 255, 255, 0.97);
  border-radius: 20px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
  overflow: hidden;
  animation: fadeIn 0.8s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.header {
  background: linear-gradient(to right, #2a9d8f, #1a2a6c);
  color: white;
  text-align: center;
  padding: 25px 20px;
  position: relative;
}

.header h1 {
  font-size: 2.5rem;
  margin-bottom: 10px;
  letter-spacing: 1px;
}

.header p {
  font-size: 1.1rem;
  opacity: 0.9;
  max-width: 80%;
  margin: 0 auto;
}

.main-content {
  display: flex;
  padding: 20px;
  gap: 30px;
  flex-direction: column;
}

.converter-section {
  flex: 1;
  min-width: 300px;
}

.info-section {
  flex: 1;
  background: #f0f9f8;
  border-radius: 15px;
  padding: 25px;
}

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

.input-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #333;
  font-size: 1.1rem;
}

.input-field {
  position: relative;
}

.input-field input {
  width: 100%;
  padding: 16px 20px;
  border: 2px solid #ddd;
  border-radius: 12px;
  font-size: 1.2rem;
  transition: all 0.3s ease;
  outline: none;
}

.input-field input:focus {
  border-color: #2a9d8f;
  box-shadow: 0 0 0 3px rgba(42, 157, 143, 0.2);
}

.unit-selectors {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 15px;
  align-items: center;
  margin-bottom: 25px;
}

.unit-box {
  background: #f9f9f9;
  border-radius: 12px;
  padding: 15px;
  border: 2px solid #eee;
  transition: all 0.3s ease;
}

.unit-box.active {
  border-color: #2a9d8f;
  box-shadow: 0 0 0 3px rgba(42, 157, 143, 0.2);
  background: #fff;
}

.unit-box label {
  display: block;
  margin-bottom: 10px;
  font-weight: 600;
  color: #444;
}

.unit-select {
  width: 100%;
  padding: 14px;
  border: 2px solid #ddd;
  border-radius: 10px;
  font-size: 1.1rem;
  background: white;
  cursor: pointer;
  transition: all 0.3s ease;
}

.unit-select:focus {
  border-color: #2a9d8f;
  outline: none;
}

.arrow {
  font-size: 2.5rem;
  color: #2a9d8f;
  display: flex;
  justify-content: center;
  align-items: center;
}

.convert-btn {
  width: 100%;
  padding: 16px;
  background: linear-gradient(to right, #2a9d8f, #1a2a6c);
  color: white;
  border: none;
  border-radius: 12px;
  font-size: 1.2rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-bottom: 25px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.convert-btn:disabled {
  background: #ccc;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.convert-btn:not(:disabled):hover {
  transform: translateY(-3px);
  box-shadow: 0 7px 20px rgba(0, 0, 0, 0.25);
}

.convert-btn:not(:disabled):active {
  transform: translateY(1px);
}

.result-container {
  background: #f0f9f8;
  border-radius: 12px;
  padding: 25px;
  text-align: center;
  border: 2px dashed #2a9d8f;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    border-color: #2a9d8f;
  }
  50% {
    border-color: #1a2a6c;
  }
  100% {
    border-color: #2a9d8f;
  }
}

.result-container h3 {
  color: #1a2a6c;
  margin-bottom: 15px;
  font-size: 1.4rem;
}

.result {
  font-size: 2.2rem;
  font-weight: 700;
  color: #e63946;
  background: linear-gradient(45deg, #1a2a6c, #e63946);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin: 10px 0;
  min-height: 60px;
}

.temperature-info {
  display: flex;
  justify-content: space-around;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid #eee;
}

.temperature-scale {
  text-align: center;
  flex: 1;
}

.temperature-scale h4 {
  color: #1a2a6c;
  margin-bottom: 8px;
}

.temperature-scale p {
  font-size: 1.1rem;
  color: #666;
}

.footer {
  text-align: center;
  padding: 20px;
  color: #777;
  font-size: 0.9rem;
  background: #fefefe;
}

.info-section h2 {
  color: #1a2a6c;
  margin-bottom: 20px;
  font-size: 1.8rem;
  text-align: center;
}

.conversion-formula {
  background: white;
  border-radius: 10px;
  padding: 15px;
  margin-bottom: 20px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.conversion-formula h3 {
  color: #2a9d8f;
  margin-bottom: 10px;
}

.conversion-formula p {
  margin-bottom: 8px;
}

.formula {
  font-family: monospace;
  background: #f5f5f5;
  padding: 8px;
  border-radius: 5px;
  display: inline-block;
  margin: 5px 0;
}

.common-temps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  margin-top: 20px;
}

.temp-card {
  background: white;
  border-radius: 10px;
  padding: 15px;
  text-align: center;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.temp-card h4 {
  color: #1a2a6c;
  margin-bottom: 8px;
}

.temp-value {
  font-weight: bold;
  font-size: 1.2rem;
  color: #e63946;
}

.seo-content {
  padding: 30px;
  background: #f9f9f9;
}

.seo-content h2 {
  color: #1a2a6c;
  margin-bottom: 20px;
  font-size: 1.8rem;
}

.seo-content h3 {
  color: #2a9d8f;
  margin: 15px 0 10px;
}

.seo-content p {
  margin-bottom: 15px;
  line-height: 1.7;
}

@media (max-width: 768px) {
  .main-content {
    flex-direction: column;
  }

  .unit-selectors {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto;
  }

  .arrow {
    transform: rotate(90deg);
    margin: 10px 0;
  }

  .header h1 {
    font-size: 1.8rem;
  }

  .result {
    font-size: 1.8rem;
  }

  .common-temps {
    grid-template-columns: 1fr;
  }
}

.copyright a {
  color: #1b316e;
  text-decoration: none;
}
