body {
  background-color: #1d2731;
  height: 100vh;
  margin: 0;
  font-family: "Roboto", sans-serif;
  padding: 20px;
  overflow: hidden;
}

main#main-content {
  align-items: center;
  display: flex;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.skip-link {
  position: fixed;
  top: -100%;
  left: 0;
  background: #41a8e5;
  color: #1d2731;
  padding: 8px 16px;
  text-decoration: none;
  z-index: 100;
  border-radius: 0 0 4px 0;
  font-weight: 500;
  transition: top 0.1s ease-in-out;
}

.skip-link:focus {
  top: 0;
}

h1 {
  color: #41a8e5;
  font-family: "Lato", sans-serif;
  font-weight: 700;
}

h2 {
  color: #d9b310;
  font-family: "Lato", sans-serif;
  font-weight: 400;
}

html {
  height: 100%;
  margin: 0;
}

a {
  color: #ffffff;
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 4px;
  transition: all 0.2s ease;
  display: inline-block;
  font-weight: 500;
}

a:hover,
a:focus {
  background-color: rgba(237, 152, 95, 0.2);
  color: #41a8e5;
  outline: 2px solid #41a8e5;
  outline-offset: 2px;
}

a:focus-visible {
  background-color: rgba(237, 152, 95, 0.2);
  color: #41a8e5;
  outline: 2px solid #41a8e5;
  outline-offset: 2px;
}

#info-container p {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: row;
  justify-content: space-evenly;
  width: 100%;
}

li {
  display: inline-block;
}

p {
  display: flex;
  flex-direction: column;
}

#content-container {
  align-content: center;
  display: flex;
  justify-content: center;
}

#name-email-grp {
  display: flex;
  flex-direction: row;
  gap: 12px;
}

textarea {
  resize: none;
  background-color: rgba(230, 230, 230, 0.1);
  border: 2px solid rgba(217, 179, 16, 0.3);
  border-radius: 4px;
  color: #ffffff;
  font-family: "Roboto", sans-serif;
  font-size: 16px;
  padding: 12px;
  transition: all 0.2s ease;
}

textarea:focus {
  outline: none;
  border-color: #d9b310;
  background-color: rgba(230, 230, 230, 0.15);
}

textarea::placeholder {
  color: rgba(230, 230, 230, 0.5);
}

input {
  background-color: rgba(230, 230, 230, 0.1);
  border: 2px solid rgba(217, 179, 16, 0.3);
  border-radius: 4px;
  color: #ffffff;
  font-family: "Roboto", sans-serif;
  font-size: 16px;
  padding: 12px;
  transition: all 0.2s ease;
}

input:focus {
  outline: none;
  border-color: #d9b310;
  background-color: rgba(230, 230, 230, 0.15);
}

input::placeholder {
  color: rgba(230, 230, 230, 0.5);
}

form {
  display: flex;
  flex-direction: column;
}

.label-input-grp {
  display: flex;
  flex-direction: column;
  position: relative;
  margin-bottom: 16px;
}

label {
  color: #ffffff;
  font-weight: 500;
  position: absolute;
  left: 12px;
  top: 12px;
  transition: all 0.2s ease;
  pointer-events: none;
  padding: 0 4px;
}

input:focus + label,
input:not(:placeholder-shown) + label,
textarea:focus + label,
textarea:not(:placeholder-shown) + label {
  top: 2px;
  left: 4px;
  font-size: 11px;
  color: #d9b310;
  transform: scale(0.85);
  transform-origin: left center;
}

label {
  color: #ffffff;
  font-weight: 500;
}

.char-count {
  color: #999;
  font-size: 12px;
  margin-top: 4px;
  align-self: flex-end;
  font-family: "Roboto", sans-serif;
}

.submit-btn {
  background-color: #41a8e5;
  border: none;
  border-radius: 4px;
  color: #1d2731;
  cursor: pointer;
  font-size: 14px;
  font-weight: bold;
  padding: 8px 16px;
  text-transform: uppercase;
  transition: all 0.2s ease;
  min-width: 80px;
  text-align: center;
}

.submit-btn:hover,
.submit-btn:focus {
  background-color: #d9b310;
  outline: 3px solid #d9b310;
  outline-offset: 2px;
}

.submit-btn:active {
  background-color: #41a8e5;
  transform: translateY(1px);
}

.submit-btn:focus-visible {
  outline: 3px solid #d9b310;
  outline-offset: 2px;
}

.submit-btn:disabled {
  background-color: #666;
  color: #999;
  cursor: not-allowed;
  opacity: 0.5;
}

.submit-btn.loading {
  background-color: #41a8e5;
  color: #ffffff;
  cursor: wait;
  opacity: 0.8;
  pointer-events: none;
  position: relative;
}

.submit-btn.loading .spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top: 2px solid #ffffff;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto;
}

.submit-btn.success {
  background-color: #4caf50;
  color: #ffffff;
}

.submit-btn.error {
  background-color: #f44336;
  color: #ffffff;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.button-group {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: flex-end;
  width: 100%;
}

.clear-btn {
  background-color: #ffffff;
  border: none;
  border-radius: 4px;
  color: #1d2731;
  cursor: pointer;
  font-size: 14px;
  font-weight: bold;
  padding: 8px 16px;
  text-transform: uppercase;
  transition: all 0.2s ease;
  height: 100%;
}

.clear-btn:hover:not(:disabled),
.clear-btn:focus:not(:disabled) {
  background-color: #d9b310;
  outline: 3px solid #d9b310;
  outline-offset: 2px;
}

.clear-btn:active:not(:disabled) {
  background-color: #41a8e5;
  transform: translateY(1px);
}

.clear-btn:focus-visible:not(:disabled) {
  outline: 3px solid #d9b310;
  outline-offset: 2px;
}

.clear-btn:disabled {
  background-color: #666;
  color: #999;
  cursor: not-allowed;
  opacity: 0.5;
}

@media (min-width: 769px) {
  #info-container {
    margin-right: 30px;
  }
}

.copyright {
  color: white;
  font-size: 12px;
  text-align: center;
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
}

@media (max-height: 700px) {
  .copyright {
    position: static;
    bottom: auto;
    left: auto;
    transform: none;
    margin-top: 30px;
    width: 100%;
  }
}

@media (max-width: 768px) {
  body {
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 10px;
    overflow-x: hidden;
    overflow-y: auto;
    height: auto;
    min-height: 100vh;
    position: relative;
  }

  main#main-content {
    flex-direction: column;
    gap: 20px;
    justify-content: flex-start;
    padding: 20px 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    height: auto;
    min-height: calc(100vh - 40px);
  }

  #info-container {
    margin-bottom: 20px;
    text-align: center;
    margin-right: 0;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
  }

  form {
    padding: 0 20px;
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
  }

  #name-email-grp {
    flex-direction: row;
    gap: 12px;
    width: 100%;
    box-sizing: border-box;
  }

  #name-email-grp .label-input-grp {
    flex: 1;
    min-width: 0;
  }

  #subject,
  #message {
    width: 100%;
    box-sizing: border-box;
  }

  h1 {
    line-height: 1.2;
    font-size: 1.8rem;
  }

  input,
  textarea {
    width: 100%;
    box-sizing: border-box;
  }
}
