/* style/contact.css */

/* Base styles for the page */
.page-contact {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: #ffffff; /* Default text color for dark body background */
  background-color: transparent; /* Main content background will be transparent to show body background */
  padding-top: var(--header-offset, 120px); /* Fixed header spacing */
}

/* Sections */
.page-contact__section {
  padding: 60px 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.page-contact__section--dark {
  background-color: #1a1a1a; /* Match body background */
  color: #ffffff;
}

.page-contact__section--light {
  background-color: #ffffff;
  color: #333333;
}

/* Hero Section */
.page-contact__hero-section {
  position: relative;
  text-align: center;
  color: #ffffff;
  padding: 100px 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 450px; /* Ensure hero has a decent height */
  overflow: hidden;
  background-color: #1a1a1a; /* Fallback/match body background */
  padding-top: var(--header-offset, 120px); /* Ensure hero content is not hidden by header */
}

.page-contact__hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
  opacity: 0.3; /* Darken background image for text readability */
}

.page-contact__hero-title {
  font-size: 3.5em;
  margin-bottom: 20px;
  color: #ffffff;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
  font-weight: bold;
}

.page-contact__hero-description {
  font-size: 1.2em;
  max-width: 800px;
  margin-bottom: 40px;
  color: #f0f0f0;
}

.page-contact__button {
  display: inline-block;
  background-color: #C30808; /* Register/Login color */
  color: #FFFF00; /* Register/Login font color */
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
  border: none;
  cursor: pointer;
  max-width: 100%; /* Ensure responsiveness */
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.page-contact__button:hover {
  background-color: #a00606;
}

.page-contact__button--secondary {
  background-color: transparent;
  color: #017439;
  border: 2px solid #017439;
}

.page-contact__button--secondary:hover {
  background-color: #017439;
  color: #ffffff;
}

/* General Headings */
.page-contact__heading-2 {
  font-size: 2.5em;
  text-align: center;
  margin-bottom: 40px;
  color: #017439; /* Brand green for headings in light sections */
  font-weight: bold;
}

.page-contact__section--dark .page-contact__heading-2 {
  color: #ffffff; /* White for headings in dark sections */
}

.page-contact__heading-3 {
  font-size: 1.8em;
  margin-bottom: 20px;
  color: #017439;
  font-weight: bold;
}

.page-contact__section--dark .page-contact__heading-3 {
  color: #ffffff;
}

.page-contact__heading-4 {
  font-size: 1.4em;
  margin-bottom: 15px;
  color: #017439;
  font-weight: bold;
}

/* Text blocks */
.page-contact__text-block {
  font-size: 1.1em;
  max-width: 900px;
  margin: 0 auto 20px;
  text-align: justify;
}

.page-contact__text-block--center {
  text-align: center;
}

/* Why Contact Section */
.page-contact__reasons-list {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 30px;
}

.page-contact__reasons-item {
  background-color: rgba(255, 255, 255, 0.1);
  padding: 20px;
  border-radius: 8px;
  text-align: center;
  color: #ffffff;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.page-contact__reasons-item h3 {
  color: #FFFF00; /* Yellow for subheadings in dark cards */
}

/* Contact Methods Section */
.page-contact__contact-methods {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-contact__method-card {
  background-color: #ffffff;
  padding: 30px;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  color: #333333; /* Dark text for light background */
}

.page-contact__method-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 20px;
  object-fit: contain;
}

.page-contact__method-card p {
  margin-bottom: 15px;
}

.page-contact__method-link {
  display: inline-block;
  background-color: #017439;
  color: #ffffff;
  padding: 10px 20px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.page-contact__method-link:hover {
  background-color: #005a2d;
}

.page-contact__method-link--email, .page-contact__method-link--phone {
  background: none;
  color: #017439;
  text-decoration: underline;
  padding: 0;
  margin: 0;
}

.page-contact__method-link--email:hover, .page-contact__method-link--phone:hover {
  color: #005a2d;
  background: none;
}

/* Contact Form Section */
.page-contact__form-container {
  background-color: #ffffff;
  padding: 40px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  max-width: 700px;
  margin: 40px auto;
  color: #333333;
}

.page-contact__form-group {
  margin-bottom: 20px;
}

.page-contact__form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: bold;
}

.page-contact__form-group input[type="text"],
.page-contact__form-group input[type="email"],
.page-contact__form-group textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 5px;
  font-size: 1em;
  box-sizing: border-box;
  color: #333333;
  background-color: #f9f9f9;
}

.page-contact__form-group textarea {
  min-height: 120px;
  resize: vertical;
}

.page-contact__submit-button {
  background-color: #017439;
  color: #ffffff;
  padding: 15px 30px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  font-size: 1.1em;
  font-weight: bold;
  transition: background-color 0.3s ease;
  width: auto; /* Allow button to size to content */
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.page-contact__submit-button:hover {
  background-color: #005a2d;
}

/* Office Location Section */
.page-contact__location-info {
  text-align: center;
  margin-bottom: 30px;
  color: #333333;
}

.page-contact__map-placeholder {
  width: 100%;
  height: 400px;
  background-color: #e0e0e0;
  border-radius: 10px;
  overflow: hidden;
  margin-top: 20px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.page-contact__map-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* FAQ Section */
.page-contact__faq-list {
  max-width: 900px;
  margin: 40px auto 0;
}

.page-contact__faq-item {
  background-color: rgba(255, 255, 255, 0.1);
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  color: #ffffff;
}

.page-contact__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  cursor: pointer;
  background-color: #017439; /* Brand green for question background */
  color: #ffffff;
  font-weight: bold;
  font-size: 1.1em;
  transition: background-color 0.3s ease;
}

.page-contact__faq-question:hover {
  background-color: #005a2d;
}

.page-contact__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  transition: transform 0.3s ease;
}

.page-contact__faq-item.active .page-contact__faq-toggle {
  transform: rotate(45deg);
}

.page-contact__faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 20px;
  transition: max-height 0.3s ease, padding 0.3s ease;
  background-color: rgba(255, 255, 255, 0.05); /* Lighter background for answer */
  color: #f0f0f0;
}

.page-contact__faq-item.active .page-contact__faq-answer {
  max-height: 1000px !important; /* Sufficiently large to show content */
  padding: 20px !important;
}

/* Responsible Gambling Section */
.page-contact__responsible-gambling-text {
  max-width: 800px;
  margin: 0 auto 30px;
  text-align: center;
  color: #333333;
}

.page-contact__cta-buttons--center {
  display: flex;
  justify-content: center;
}

/* Final CTA Section */
.page-contact__cta-section {
  text-align: center;
  padding: 80px 20px;
  background-color: #017439;
  color: #ffffff;
}

.page-contact__cta-title {
  font-size: 2.8em;
  margin-bottom: 25px;
  color: #ffffff;
}

.page-contact__cta-description {
  font-size: 1.1em;
  max-width: 700px;
  margin: 0 auto 40px;
  color: #f0f0f0;
}

.page-contact__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap; /* Allow wrapping on smaller screens */
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

.page-contact__cta-button--register {
  background-color: #C30808;
  color: #FFFF00;
}

.page-contact__cta-button--login {
  background-color: #C30808;
  color: #FFFF00;
}

/* Images */
.page-contact img {
  max-width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

/* Responsive styles */
@media (max-width: 1024px) {
  .page-contact__hero-title {
    font-size: 3em;
  }
  .page-contact__heading-2 {
    font-size: 2.2em;
  }
}

@media (max-width: 768px) {
  .page-contact {
    font-size: 16px;
    line-height: 1.6;
    padding-left: 0;
    padding-right: 0;
  }

  .page-contact__section {
    padding: 40px 15px;
  }

  .page-contact__hero-section {
    padding: 80px 15px;
    min-height: 300px;
    padding-top: var(--header-offset, 120px) !important; /* Important for mobile */
  }

  .page-contact__hero-title {
    font-size: 2.2em;
  }

  .page-contact__hero-description {
    font-size: 1em;
  }

  .page-contact__heading-2 {
    font-size: 2em;
  }

  .page-contact__heading-3 {
    font-size: 1.5em;
  }

  .page-contact__reasons-list,
  .page-contact__contact-methods {
    grid-template-columns: 1fr;
  }

  .page-contact__method-card,
  .page-contact__form-container,
  .page-contact__faq-item {
    padding-left: 15px;
    padding-right: 15px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-contact__form-container {
    margin: 20px auto;
  }

  .page-contact__submit-button,
  .page-contact__button,
  .page-contact__method-link {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px; /* Add padding to button content itself */
    padding-right: 15px;
  }

  .page-contact__cta-buttons {
    flex-direction: column;
    gap: 15px;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-contact__cta-button--register,
  .page-contact__cta-button--login {
    width: 100%;
  }

  /* Image responsiveness */
  .page-contact img {
    max-width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  /* Ensure content sections don't overflow */
  .page-contact__section,
  .page-contact__form-container,
  .page-contact__map-placeholder,
  .page-contact__faq-list,
  .page-contact__cta-section {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  .page-contact__faq-answer {
    padding: 0 15px; /* Adjust padding for mobile */
  }
  .page-contact__faq-item.active .page-contact__faq-answer {
    padding: 15px !important;
  }
}

@media (max-width: 480px) {
  .page-contact__hero-title {
    font-size: 1.8em;
  }

  .page-contact__heading-2 {
    font-size: 1.8em;
  }

  .page-contact__heading-3 {
    font-size: 1.3em;
  }
}

/* Ensure contrast for text on dark body background */
.page-contact p,
.page-contact li,
.page-contact a {
  color: #f0f0f0; /* Default text color for dark body background */
}

/* Specific elements on light backgrounds will override */
.page-contact__method-card,
.page-contact__form-container,
.page-contact__location-info,
.page-contact__responsible-gambling-text {
  color: #333333; /* Dark text for light background */
}

.page-contact__form-group input,
.page-contact__form-group textarea {
  color: #333333; /* Dark text for input fields */
}

/* Links in dark sections */
.page-contact__section--dark a,
.page-contact__hero-section a {
  color: #FFFF00; /* Yellow for links on dark background */
  text-decoration: underline;
}

.page-contact__section--dark a:hover,
.page-contact__hero-section a:hover {
  color: #f0f000;
}