/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  /* background-color: #f2f2f2; */
  color: #333;
}

main {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  /* align-items: center; */
  justify-content: center;
  padding: 2rem;
  background-color: hsl(0, 0%, 100%);
}

/* Layout container */
section {
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  /* overflow: hidden; */
  max-width: 900px;
  width: 100%;
  display: flex;
  flex-direction: column;
}

/* Image side */
.news-side-img img {
  width: 100%;
  height: auto;
  /* display: block; */
}

/* Text content */
.text-side {
  padding: 2rem;
}

.text-side h1 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.text-side p {
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
}

.text-side i {
  color: #e44d26;
  margin-right: 0.5rem;
}

/* Form */
.form-side {
  margin-top: 1.5rem;
}

.form-label {
  font-size: 0.85rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
}

input[type="text"] {
  width: 100%;
  padding: 0.75rem;
  border-radius: 8px;
  border: 1px solid #ccc;
  font-size: 1rem;
  margin-bottom: 1rem;
}

button {
  width: 100%;
  padding: 0.75rem;
  background-color: #242742;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.3s ease;
}

button:hover {
  background-color: #444;
}

/* Responsive styles */
.desktop-image {
  display: none;
}
/* .sucess-message i {
  color: #e44d26;
  font-size: 3rem;
}
.sucess-message {
  margin-right: 2rem;
} */

/* Success message */
/* .success-message {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: #fff;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  max-width: 400px;
  width: 90%;
  z-index: 9999;
  text-align: center;
  display: block; 
}

.success-message i {
  color: #e44d26;
  font-size: 3rem;
  margin-bottom: 1rem;
}

.success-message h1 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.success-message p {
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}

.success-message span {
  font-weight: bold;
}

.success-message button {
  background-color: #242742;
  color: #fff;
  padding: 0.75rem 1rem;
  border: none;
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.3s ease;
  width: 100%;
}

.success-message button:hover {
  background-color: #444;
} */

/* Base success message */

/* Success message */
.success-message {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: #fff;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  max-width: 400px;
  width: 90%;
  /* min-height: 60vh; */
  z-index: 9999;
  text-align: start;
  display: none; /* Hide by default */
}

.success-message i {
  color: #e44d26;
  font-size: 3rem;
  margin-bottom: 1rem;
}

.success-message h1 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.success-message p {
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}

.success-message span {
  font-weight: bold;
}

.success-message button {
  background-color: #242742;
  color: #fff;
  padding: 0.75rem 1rem;
  border: none;
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.3s ease;
  width: 100%;
  margin-top: 3rem;
}

.success-message button:hover {
  background-color: #444;
}

@media (min-width: 1024px) {
  section {
    flex-direction: row-reverse;
    align-items: center;
    padding: 1.3rem;
    margin: auto;
    background-color: hsl(0, 0%, 100%);
  }
  main {
    background-color: hsl(235, 18%, 26%);
    /* position: relative; */
  }
  /* .sucess-message {
    position: absolute;
    top: 10px;
     left: 40px;
    transform: translateX(-30%);
  }  */

  .news-side-img {
    flex: 1;
  }

  .text-side {
    flex: 1;
    padding: 3rem;
  }

  .desktop-image {
    display: block;
  }

  .mobile-image {
    display: none;
  }
  .success-message button {
    margin-top: 0;
  }
}

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

@media (min-width: 1440px) {
  .desktop-image {
    display: block;
  }

  .mobile-image {
    display: none;
  }
}
