/* Base styles for page-about */
.page-about {
  font-family: 'Arial', sans-serif;
  color: #333333; /* Default dark text for light body background */
  background: #ffffff; /* Default body background */
  line-height: 1.6;
}

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

.page-about__section {
  padding: 60px 0;
  text-align: center;
}

.page-about__section:nth-of-type(even) {
  background-color: #f9f9f9;
}

.page-about__section-title {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 30px;
  color: #017439;
  position: relative;
  padding-bottom: 10px;
}

.page-about__section-title::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background-color: #017439;
  border-radius: 2px;
}

.page-about__text-block {
  font-size: 18px;
  margin-bottom: 25px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  color: #555555;
}

.page-about__text-block--centered {
  text-align: center;
}

/* Hero Section */
.page-about__hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 10px; /* Small top padding, relying on body for header offset */
  padding-bottom: 40px;
  background-color: #f0f0f0;
}

.page-about__hero-image-wrapper {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  margin-bottom: 30px;
}

.page-about__hero-image {
  width: 100%;
  height: 675px;
  object-fit: cover;
  display: block;
}

.page-about__hero-content {
  max-width: 900px;
  text-align: center;
  padding: 0 20px;
}

.page-about__main-title {
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  font-weight: 800;
  color: #017439;
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-about__description {
  font-size: 20px;
  color: #555555;
  margin-bottom: 30px;
  line-height: 1.5;
}

.page-about__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.page-about__btn-primary,
.page-about__btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 15px 30px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.3s ease;
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
  min-width: 180px;
}

.page-about__btn-primary {
  background: #C30808; /* Custom color for register/login */
  color: #FFFF00; /* Custom color for register/login font */
  border: 2px solid #C30808;
}

.page-about__btn-primary:hover {
  background: #e00a0a;
  border-color: #e00a0a;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(195, 8, 8, 0.3);
}

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

.page-about__btn-secondary:hover {
  background: #005a2e;
  border-color: #005a2e;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(1, 116, 57, 0.3);
}

/* Vision Section */
.page-about__section--vision {
  background-color: #FFFFFF;
}

.page-about__vision-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
  margin-bottom: 50px;
}

.page-about__vision-item {
  text-align: left;
  background: #f9f9f9;
  border-radius: 10px;
  padding: 30px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.page-about__vision-image {
  width: 100%;
  height: 300px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
}

.page-about__item-title {
  font-size: 24px;
  font-weight: 700;
  color: #017439;
  margin-bottom: 15px;
}

.page-about__vision-item p {
  font-size: 16px;
  color: #555555;
  line-height: 1.6;
}

.page-about__values {
  text-align: left;
  background: #f0f8f0;
  border-radius: 10px;
  padding: 30px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.page-about__value-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 15px;
}

.page-about__value-list li {
  font-size: 16px;
  color: #333333;
  line-height: 1.5;
  position: relative;
  padding-left: 25px;
}

.page-about__value-list li::before {
  content: '✔';
  color: #017439;
  font-weight: bold;
  position: absolute;
  left: 0;
  top: 0;
}

/* History Section */
.page-about__section--history {
  background-color: #f9f9f9;
}

.page-about__timeline {
  display: flex;
  flex-direction: column;
  position: relative;
  max-width: 800px;
  margin: 50px auto;
  padding: 0 20px;
}

.page-about__timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  width: 4px;
  height: 100%;
  background: #e0e0e0;
  transform: translateX(-50%);
}

.page-about__timeline-item {
  padding: 20px 0;
  position: relative;
  width: 50%;
}

.page-about__timeline-item:nth-child(odd) {
  align-self: flex-start;
  padding-right: 40px;
  text-align: right;
}

.page-about__timeline-item:nth-child(even) {
  align-self: flex-end;
  padding-left: 40px;
  text-align: left;
}

.page-about__timeline-item::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  background: #017439;
  border: 4px solid #ffffff;
  border-radius: 50%;
  top: 30px;
  z-index: 1;
}

.page-about__timeline-item:nth-child(odd)::after {
  right: -10px;
}

.page-about__timeline-item:nth-child(even)::after {
  left: -10px;
}

.page-about__timeline-year {
  font-size: 22px;
  font-weight: 700;
  color: #017439;
  margin-bottom: 10px;
}

.page-about__timeline-item p {
  font-size: 16px;
  color: #555555;
}

.page-about__history-image {
  width: 100%;
  max-width: 800px;
  height: auto;
  object-fit: cover;
  border-radius: 10px;
  margin-top: 50px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

/* Advantages Section */
.page-about__section--advantages {
  background-color: #FFFFFF;
}

.page-about__advantages-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-about__advantage-card {
  background: #f9f9f9;
  border-radius: 10px;
  padding: 30px;
  text-align: left;
  box-shadow: 0 5px 15px rgba(0,0,0,0.05);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.page-about__card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
}

.page-about__card-title {
  font-size: 22px;
  font-weight: 700;
  color: #017439;
  margin-bottom: 15px;
}

.page-about__advantage-card p {
  font-size: 16px;
  color: #555555;
  line-height: 1.6;
}

/* Team Section */
.page-about__section--team {
  background-color: #f9f9f9;
}

.page-about__team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-about__team-member {
  background: #FFFFFF;
  border-radius: 10px;
  padding: 30px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.05);
  text-align: center;
}

.page-about__team-photo {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 20px;
  border: 4px solid #017439;
}

.page-about__member-name {
  font-size: 20px;
  font-weight: 700;
  color: #017439;
  margin-bottom: 5px;
}

.page-about__member-position {
  font-size: 16px;
  color: #777777;
  margin-bottom: 15px;
}

.page-about__member-description {
  font-size: 15px;
  color: #555555;
  line-height: 1.6;
}

/* FAQ Section */
.page-about__section--faq {
  background-color: #FFFFFF;
}

details.page-about__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  border: 1px solid #e0e0e0;
  overflow: hidden;
  background: #fff;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}
details.page-about__faq-item summary.page-about__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  cursor: pointer;
  user-select: none;
  list-style: none;
  transition: background-color 0.3s ease;
}
details.page-about__faq-item summary.page-about__faq-question::-webkit-details-marker {
  display: none;
}
details.page-about__faq-item summary.page-about__faq-question:hover {
  background: #f5f5f5;
}
.page-about__faq-qtext {
  flex: 1;
  font-size: 17px;
  font-weight: 600;
  line-height: 1.5;
  text-align: left;
  color: #333333;
}
.page-about__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  color: #017439;
  flex-shrink: 0;
  margin-left: 15px;
  width: 28px;
  text-align: center;
}
details.page-about__faq-item .page-about__faq-answer {
  padding: 0 20px 20px;
  background: #f9f9f9;
  border-radius: 0 0 5px 5px;
  text-align: left;
}
details.page-about__faq-item .page-about__faq-answer p {
  font-size: 16px;
  color: #555555;
  line-height: 1.6;
}

/* Contact CTA Section */
.page-about__section--contact-cta {
  background: linear-gradient(135deg, #017439, #005a2e);
  color: #FFFFFF;
  padding: 80px 0;
}

.page-about__container--flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-align: left;
  gap: 30px;
}

.page-about__contact-content {
  flex: 2;
}

.page-about__contact-content .page-about__section-title {
  color: #FFFFFF;
  text-align: left;
}

.page-about__contact-content .page-about__section-title::after {
  background-color: #FFFFFF;
  left: 0;
  transform: translateX(0);
}

.page-about__contact-content .page-about__text-block {
  color: #f0f0f0;
  text-align: left;
  max-width: none;
  margin-left: 0;
  margin-right: 0;
}

.page-about__contact-buttons {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 15px;
  align-items: flex-end;
}

.page-about__contact-buttons .page-about__btn-primary {
  background: #C30808;
  color: #FFFF00;
  border-color: #C30808;
  min-width: 200px;
}

.page-about__contact-buttons .page-about__btn-primary:hover {
  background: #e00a0a;
  border-color: #e00a0a;
}

.page-about__contact-buttons .page-about__btn-secondary {
  background: #FFFFFF;
  color: #017439;
  border-color: #FFFFFF;
  min-width: 200px;
}

.page-about__contact-buttons .page-about__btn-secondary:hover {
  background: #f0f0f0;
  border-color: #f0f0f0;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-about__container {
    padding: 0 15px;
  }
  .page-about__section-title {
    font-size: 32px;
  }
  .page-about__description {
    font-size: 18px;
  }
  .page-about__vision-grid,
  .page-about__advantages-grid,
  .page-about__team-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }
  .page-about__timeline-item:nth-child(odd),
  .page-about__timeline-item:nth-child(even) {
    width: 100%;
    padding-left: 0;
    padding-right: 0;
    text-align: left;
  }
  .page-about__timeline::before {
    left: 20px;
  }
  .page-about__timeline-item::after {
    left: 10px;
  }
  .page-about__timeline-item:nth-child(odd)::after {
    right: auto;
  }
  .page-about__timeline-item:nth-child(odd) {
    padding-right: 0;
  }
  .page-about__value-list {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  }
}

@media (max-width: 768px) {
  .page-about__section {
    padding: 40px 0;
  }
  .page-about__section-title {
    font-size: 28px;
    margin-bottom: 20px;
  }
  .page-about__text-block {
    font-size: 16px;
    margin-bottom: 20px;
  }
  .page-about__hero-section {
    padding-top: 10px; /* Still small top padding */
    padding-bottom: 30px;
  }
  .page-about__hero-image-wrapper {
    margin-bottom: 20px;
  }
  .page-about__hero-image {
    height: 450px !important;
    object-fit: cover !important;
    max-width: 100% !important;
    width: 100% !important;
  }
  .page-about__hero-content {
    padding: 0 15px;
  }
  .page-about__main-title {
    font-size: clamp(1.8rem, 6vw, 2.5rem);
    margin-bottom: 15px;
  }
  .page-about__description {
    font-size: 16px;
    margin-bottom: 25px;
  }
  .page-about__cta-buttons {
    flex-direction: column;
    gap: 15px;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    padding: 0 15px;
  }
  .page-about__btn-primary,
  .page-about__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    padding: 12px 20px;
    font-size: 16px;
    min-width: unset;
  }

  .page-about__vision-grid {
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 30px;
  }
  .page-about__vision-item {
    padding: 20px;
  }
  .page-about__vision-image {
    height: 250px;
  }
  .page-about__item-title {
    font-size: 20px;
  }
  .page-about__values {
    padding: 20px;
  }
  .page-about__value-list {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .page-about__timeline {
    margin: 30px auto;
    padding: 0;
  }
  .page-about__timeline::before {
    left: 15px;
  }
  .page-about__timeline-item::after {
    left: 5px;
  }
  .page-about__timeline-year {
    font-size: 18px;
  }
  .page-about__history-image {
    margin-top: 30px;
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  .page-about__advantages-grid {
    grid-template-columns: 1fr;
    gap: 20px;
    margin-top: 30px;
  }
  .page-about__advantage-card {
    padding: 20px;
  }
  .page-about__card-image {
    height: 180px;
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .page-about__card-title {
    font-size: 20px;
  }

  .page-about__team-grid {
    grid-template-columns: 1fr;
    gap: 20px;
    margin-top: 30px;
  }
  .page-about__team-member {
    padding: 20px;
  }
  .page-about__team-photo {
    width: 120px;
    height: 120px;
  }
  .page-about__member-name {
    font-size: 18px;
  }
  .page-about__member-position {
    font-size: 14px;
  }

  details.page-about__faq-item summary.page-about__faq-question { padding: 15px; }
  .page-about__faq-qtext { font-size: 15px; }
  details.page-about__faq-item .page-about__faq-answer { padding: 0 15px 15px; }
  details.page-about__faq-item .page-about__faq-answer p { font-size: 15px; }

  .page-about__section--contact-cta {
    padding: 50px 0;
  }
  .page-about__container--flex {
    flex-direction: column;
    text-align: center;
    gap: 20px;
    padding: 0 15px;
  }
  .page-about__contact-content .page-about__section-title {
    text-align: center;
  }
  .page-about__contact-content .page-about__section-title::after {
    left: 50%;
    transform: translateX(-50%);
  }
  .page-about__contact-content .page-about__text-block {
    text-align: center;
  }
  .page-about__contact-buttons {
    align-items: center;
    width: 100%;
  }
  .page-about__contact-buttons .page-about__btn-primary,
  .page-about__contact-buttons .page-about__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    min-width: unset;
  }

  /* General image and button overflow prevention for mobile */
  .page-about img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .page-about__section,
  .page-about__card,
  .page-about__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-about__cta-button,
  .page-about__btn-primary,
  .page-about__btn-secondary,
  .page-about a[class*="button"],
  .page-about a[class*="btn"] {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-about__cta-buttons,
  .page-about__button-group,
  .page-about__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    flex-wrap: wrap !important;
    gap: 10px;
    display: flex;
    flex-direction: column;
  }
}