/* css/weight-converter.css */
body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background: #f7fbfa;
  color: #333;
  margin: 0;
  min-height: 100vh;
  line-height: 1.6;
  direction: rtl;
  text-align: right;
}

main {
  max-width: 800px;
 margin: 1.5rem auto 3rem;
 padding: 0 1rem;
 background: #ffffff;
 border: 2px solid #3a997a;
 border-radius: 6px;
}

#header-placeholder,
#footer-placeholder,
#header-placeholder > *,
#footer-placeholder > * {
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  box-sizing: border-box !important;
}

h1 {
  text-align: center;
  color: #000000;
  margin-bottom: 1.5rem;
  font-weight: 700;
}

form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form-group label {
  font-weight: 600;
  color: #000000;
  margin-bottom: 0.3rem;
  display: block;
  cursor: pointer;
}

.form-group input[type="number"],
.form-group select {
  padding: 0.5rem 1rem;
  font-size: 1rem;
  border-radius: 8px;
  border: 1px solid #3a997a;
  outline-offset: -2px;
  outline-color: transparent;
  transition: outline-color 0.35s ease-in-out, border-color 0.35s ease-in-out;
  box-sizing: border-box;
  direction: rtl;
  width: 100%;
}

.form-group input[type="number"]:focus,
.form-group select:focus {
  border-color: #2c86c9;
  outline-color: #a2cdfb;
}

.buttons-group {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.btn-submit,
.btn-reset {
  padding: 0.75rem 2.5rem;
  font-weight: 700;
  font-size: 1.1rem;
  border-radius: 10px;
  cursor: pointer;
  border: none;
  user-select: none;
  width: fit-content;
  min-width: 120px;
  text-align: center;
  transition: background-color 0.3s ease;
}

.btn-submit {
  background-color: #3a997a;
  color: #fff;
}

.btn-submit:disabled {
  background-color: #8cc9b5;
  cursor: not-allowed;
}

.btn-submit:hover:not(:disabled),
.btn-submit:focus:not(:disabled) {
  background-color: #286a50;
  outline: none;
  box-shadow: 0 4px 12px rgba(32, 96, 63, 0.4);
}

.btn-reset {
  background-color: #a3a3a3;
  color: #fff;
}

.btn-reset:hover,
.btn-reset:focus {
  background-color: #7d7d7d;
  outline: none;
  box-shadow: 0 4px 12px rgba(100, 100, 100, 0.5);
}

#result {
  border: 2px solid #3a997a;
  border-radius: 12px;
  padding: 1.5rem;
  background-color: #e6f3eb;
  color: #20603f;
  font-weight: 700;
  font-size: 1.3rem;
  text-align: center;
  user-select: text;
  margin-top: 2rem;
}

#result h2 {
  margin-top: 0;
  margin-bottom: 1rem;
}

[aria-label="تعليمات استخدام أداة تحويل الوزن"] {
  margin-top: 3rem;
  color: #1a2e6a;
  line-height: 1.6;
  max-width: 800px;
  width: 100%;
  
    
}

[aria-label="تعليمات استخدام أداة تحويل الوزن"] h2 {
  font-weight: 700;
  margin-top: 2rem;
  margin-bottom: 0.6rem;
  color: #000000;
  border-bottom: 3px solid #3a997a;
  padding-bottom: 0.3rem;
}

[aria-label="تعليمات استخدام أداة تحويل الوزن"] ul {
  list-style: disc inside;
  margin: 0 0 1rem 0;
  padding-left: 1rem;
}

@media (max-width: 480px) {
  main {
    margin: 1.5rem 1rem 3rem;
    padding: 1.5rem 1.5rem 2.5rem;
  }
  .buttons-group {
    flex-direction: column;
    gap: 0.8rem;
  }
  .btn-submit,
  .btn-reset {
    width: 100%;
    min-width: auto;
  }
  [aria-label="تعليمات استخدام أداة تحويل الوزن"] {
    max-width: 100%;
    margin: 3rem 0 0 0;
    padding: 0 1rem;
  }
}