/* style/register.css */

/* Root variables for consistent spacing and colors */
:root {
  --primary-color: #017439;
  --secondary-color: #FFFFFF;
  --text-dark: #333333;
  --text-light: #ffffff;
  --button-register-bg: #017439; /* Using primary color for contrast */
  --button-register-text: #ffffff; /* Using white for contrast */
  --button-login-bg: #ffffff; /* Using auxiliary color for secondary button */
  --button-login-text: #017439; /* Using primary color for secondary button text */
  --border-color: #e0e0e0;
  --spacing-unit: 1rem;
  --header-offset: 120px; /* Fallback, actual value from shared.css */
}

/* Base styles for the page-register scope */
.page-register {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-dark); /* Default text color for light background */
  background-color: var(--secondary-color); /* Body background is white */
}

/* Hero Section */
.page-register__hero-section {
  position: relative;
  background-color: var(--primary-color); /* Dark background */
  color: var(--text-light);
  padding: calc(var(--header-offset) + 60px) 20px 60px;
  text-align: center;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 500px;
}

.page-register__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
  box-sizing: border-box;
}

.page-register__hero-title {
  font-size: 2.8rem;
  margin-bottom: 1rem;
  line-height: 1.2;
  color: var(--text-light);
}

.page-register__hero-description {
  font-size: 1.2rem;
  margin-bottom: 2rem;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  color: var(--text-light);
}

.page-register__cta-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
}

.page-register__btn-primary,
.page-register__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: bold;
  text-decoration: none;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  box-sizing: border-box;
  text-align: center;
  white-space: normal;
  word-wrap: break-word;
  max-width: 100%;
}

.page-register__btn-primary {
  background-color: var(--button-register-bg);
  color: var(--button-register-text);
  border: 2px solid var(--button-register-bg);
}

.page-register__btn-primary:hover {
  background-color: #005f2c; /* Darker green */
  border-color: #005f2c;
}

.page-register__btn-secondary {
  background-color: var(--button-login-bg);
  color: var(--button-login-text);
  border: 2px solid var(--button-login-text);
}

.page-register__btn-secondary:hover {
  background-color: #f0f0f0;
  color: #005f2c;
  border-color: #005f2c;
}

/* Content Sections */
.page-register__content-section {
  padding: 60px 0;
}

.page-register__section-title {
  font-size: 2.2rem;
  text-align: center;
  margin-bottom: 40px;
  color: var(--primary-color);
}

.page-register__text-block {
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
  text-align: justify;
}

.page-register__image-full-width {
  width: 100%;
  height: auto;
  display: block;
  margin: 0 auto 30px;
  border-radius: 8px;
  object-fit: cover;
}

.page-register__image-small {
  width: 100%;
  max-width: 600px;
  height: auto;
  display: block;
  margin: 0 auto 20px;
  border-radius: 8px;
  object-fit: cover;
}

/* Step-by-step Section */
.page-register__step-by-step {
  background-color: #f9f9f9;
}

.page-register__step-card {
  background-color: var(--secondary-color);
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  margin-bottom: 30px;
  text-align: center;
}

.page-register__step-title {
  font-size: 1.8rem;
  color: var(--primary-color);
  margin-bottom: 15px;
}

.page-register__step-description {
  font-size: 1rem;
  text-align: justify;
  margin-bottom: 1rem;
}

.page-register__note {
  font-style: italic;
  color: #666;
  text-align: center;
}

/* Promotions Section */
.page-register__promotions-section {
  background-color: var(--primary-color);
  color: var(--text-light);
}

.page-register__promotions-section .page-register__section-title {
  color: var(--text-light);
}

.page-register__promotions-section .page-register__text-block {
  color: var(--text-light);
}

/* Security Section */
.page-register__security-section {
  background-color: var(--secondary-color);
}

/* Terms Section */
.page-register__terms-section {
  background-color: var(--primary-color);
  color: var(--text-light);
}

.page-register__terms-section .page-register__section-title {
  color: var(--text-light);
}

.page-register__terms-section .page-register__text-block {
  color: var(--text-light);
}

/* Support Section */
.page-register__support-section {
  background-color: var(--secondary-color);
}

/* List Styles */
.page-register__list {
  list-style: disc inside;
  margin-bottom: 1.5rem;
  padding-left: 20px;
}

.page-register__list-item {
  margin-bottom: 0.5rem;
  font-size: 1.05rem;
}

/* FAQ Section */
.page-register__faq-section {
  background-color: #f9f9f9;
}

.page-register__faq-list {
  max-width: 900px;
  margin: 0 auto;
}

.page-register__faq-item {
  background-color: var(--secondary-color);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
}

.page-register__faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1.1rem;
  font-weight: bold;
  color: var(--primary-color);
  position: relative;
  user-select: none;
}

.page-register__faq-item summary::-webkit-details-marker {
  display: none;
}

.page-register__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.page-register__faq-qtext {
  flex-grow: 1;
  text-align: left;
  padding-right: 10px;
}

.page-register__faq-toggle {
  font-size: 1.5rem;
  font-weight: normal;
  color: var(--primary-color);
  transition: transform 0.3s ease;
}

.page-register__faq-item[open] .page-register__faq-toggle {
  transform: rotate(0deg); /* +/- is handled by JS, no rotation needed */
}

.page-register__faq-answer {
  padding: 0 20px 20px;
  font-size: 1rem;
  color: var(--text-dark);
  text-align: justify;
}

/* Color Contrast System Classes */
.page-register__dark-bg {
  background-color: var(--primary-color);
  color: var(--text-light);
}

.page-register__light-bg {
  background-color: var(--secondary-color);
  color: var(--text-dark);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-register__hero-title {
    font-size: 2.4rem;
  }

  .page-register__section-title {
    font-size: 2rem;
  }
}

@media (max-width: 768px) {
  /* Fixed header offset for mobile */
  .page-register__hero-section {
    padding-top: calc(var(--header-offset) + 30px);
    min-height: 400px;
  }

  .page-register__hero-title {
    font-size: 2rem;
  }

  .page-register__hero-description {
    font-size: 1rem;
  }

  .page-register__cta-buttons {
    flex-direction: column;
    gap: 15px;
  }

  .page-register__btn-primary,
  .page-register__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    padding: 12px 20px;
    font-size: 1rem;
  }

  .page-register__section-title {
    font-size: 1.8rem;
  }

  .page-register__text-block,
  .page-register__list-item,
  .page-register__step-description,
  .page-register__faq-item summary,
  .page-register__faq-answer {
    font-size: 16px;
    line-height: 1.6;
  }

  .page-register__step-title {
    font-size: 1.5rem;
  }

  .page-register__container {
    padding: 0 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  /* Mobile image responsive adaptations */
  .page-register img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
    box-sizing: border-box !important;
  }
  
  .page-register__content-section,
  .page-register__step-card,
  .page-register__faq-list,
  .page-register__faq-item {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
}

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

  .page-register__section-title {
    font-size: 1.6rem;
  }
  
  .page-register__hero-section {
    min-height: 350px;
  }
}