html {
  height: 100%;
  margin: 0;
  background-color: rgb(69, 69, 69);
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

body {
  display: flex;
  flex-direction: column;
  height: 100%;
  margin: 0;
}

.main-container {
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  flex: 1;
}

.calc-body {
  width: clamp(336px, 31.5vw, 600px);
  /* height: clamp(432px, 42vw, 800px); */
  display: flex;
  flex-direction: column;
  border-radius: 16px;
}

.screen-container {
  flex: 1.25;
  background-color: rgb(18, 18, 18);
  border-top-right-radius: 16px;
  border-top-left-radius: 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.screen-container > h3 {
  color: white;
  font-weight: 400;
  margin: 8px 0 10px 10px;
  font-size: clamp(0.69rem, 1.16vw, 1.4rem);
  word-wrap: break-word;
}

.screen {
  width: 84%;
  min-height: clamp(95.5px, 9.54vw, 183.5px);
  background-color: rgb(200, 200, 200);
  align-self: center;
  margin-bottom: clamp(18px, 1.6vw, 30px);
  display: flex;
  flex-direction: column;
  padding: clamp(11px, 1.05vw, 20px);
  box-sizing: border-box;
  font-weight: bold;
}

.upper-screen {
  flex: 1.2;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  font-size: clamp(17px, 1.7vw, 32px);

  word-break: break-all;
}

.lower-screen {
  flex: 2;
  display: flex;
  justify-content: flex-end;
  font-size: clamp(30px, 2.8vw, 52px);
  align-items: center;
  box-sizing: border-box;
  word-break: break-all;
}

.buttons-container {
  flex: 2;
  background-color: rgb(176, 176, 176);
  border-bottom-left-radius: 16px;
  border-bottom-right-radius: 16px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-template-rows: repeat(4, 1fr);
  color: white;
  gap: clamp(8px, 0.84vw, 16px);
  padding: clamp(20px, 1.6vw, 30px) clamp(18px, 1.25vw, 24px)
    clamp(30px, 1.9vw, 36px) clamp(18px, 1.25vw, 24px);
}

.numbers {
  background-color: rgb(42, 42, 42);
  display: flex;
  justify-content: center;
  align-items: center;
  border: none;
  color: white;
  font-size: clamp(20px, 2.1vw, 40px);
  border-radius: 10px;
  padding-top: clamp(14px, 1.36vw, 26px);
  padding-bottom: clamp(14px, 1.36vw, 26px);
}

.operations {
  background-color: rgb(92, 92, 92);
  display: flex;
  justify-content: center;
  align-items: center;
  border: none;
  color: white;
  border-radius: 10px;
  font-size: clamp(20px, 2.1vw, 40px);
}

.edit {
  background-color: #d4727f;
  display: flex;
  justify-content: center;
  align-items: center;
  border: none;
  color: white;
  border-radius: 10px;
  font-size: clamp(20px, 2.1vw, 40px);
}

button {
  transition: all 0.1s ease-out;
}

button:active {
  transform: scale(0.95);
}

.footer {
  display: flex;
  justify-content: center;
  width: 100%;
  margin: 8px 0 8px 0;
}

.footer > a {
  text-align: center;
  color: white;
  text-decoration: none;
  font-size: clamp(12px, 1.5vw, 18px);
  display: inline;
}

.footer > a > img {
  width: clamp(12px, 1.5vw, 18px);
  border-radius: 50%;
  margin-left: 6px;
}
