/* style/cockfighting.css */

/* Variables and Base Styles */
:root {
  --primary-color: #017439;
  --secondary-color: #FFFFFF;
  --register-button-color: #C30800;
  --login-button-color: #C30800;
  --register-login-font-color: #FFFF00; /* Custom color for register/login text */
  --text-color-dark: #333333;
  --text-color-light: #ffffff;
  --font-family: 'Arial', sans-serif;
  --border-radius-default: 8px;
  --spacing-large: 60px;
  --spacing-medium: 40px;
  --spacing-small: 20px;
}

.page-cockfighting {
  font-family: var(--font-family);
  line-height: 1.6;
  color: var(--text-color-dark); /* Default text color for light backgrounds */
  background-color: var(--secondary-color); /* Body background is light */
}

/* Hero Section */
.page-cockfighting__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--spacing-large) var(--spacing-small);
  padding-top: var(--header-offset, 120px); /* Fixed header spacing */
  background: linear-gradient(135deg, var(--primary-color), #004d26); /* Darker green gradient */
  color: var(--text-color-light); /* Light text for dark background */
  overflow: hidden; /* Prevent image overflow */
}

.page-cockfighting__hero-container {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.page-cockfighting__hero-image {
  width: 100%;
  margin-bottom: var(--spacing-small);
  max-width: 900px; /* Constrain hero image width */
}

.page-cockfighting__hero-image img {
  width: 100%;
  height: auto;
  max-width: 100%;
  display: block;
  border-radius: var(--border-radius-default);
  object-fit: cover;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.page-cockfighting__hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  width: 100%;
  max-width: 800px;
}

.page-cockfighting__hero-content h1 {
  font-size: 2.8em;
  margin-bottom: 15px;
  color: var(--text-color-light);
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
}

.page-cockfighting__hero-content p {
  font-size: 1.2em;
  margin-bottom: 30px;
  color: var(--text-color-light);
  opacity: 0.9;
}

.page-cockfighting__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap; /* Allow wrapping on smaller screens */
  width: 100%; /* Ensure container takes full width */
}

.page-cockfighting__cta-button {
  display: inline-block;
  padding: 15px 40px;
  text-decoration: none;
  border-radius: 5px;
  font-size: 18px;
  font-weight: bold;
  transition: all 0.3s ease;
  box-sizing: border-box; /* Include padding in width */
  max-width: 100%; /* Ensure buttons don't overflow */
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow long words to break */
}

.page-cockfighting__btn-register {
  background: var(--register-button-color);
  color: var(--register-login-font-color); /* Custom color for register text */
  border: 2px solid var(--register-button-color);
}

.page-cockfighting__btn-register:hover {
  background: #A80707; /* Darker shade of #C30808 */
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.page-cockfighting__btn-login {
  background: var(--login-button-color);
  color: var(--register-login-font-color); /* Custom color for login text */
  border: 2px solid var(--login-button-color);
}

.page-cockfighting__btn-login:hover {
  background: #A80707; /* Darker shade of #C30808 */
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* General Section Styles */
.page-cockfighting__section {
  padding: var(--spacing-large) var(--spacing-small);
  text-align: center;
}

.page-cockfighting__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-small);
  box-sizing: border-box;
}

.page-cockfighting__section-title {
  font-size: 2.2em;
  margin-bottom: 20px;
  color: var(--primary-color);
}

.page-cockfighting__section-description {
  font-size: 1.1em;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  color: var(--text-color-dark);
}

/* Background Color Handling */
.page-cockfighting__dark-section {
  background-color: var(--primary-color);
  color: var(--text-color-light);
}

.page-cockfighting__dark-section .page-cockfighting__section-title,
.page-cockfighting__dark-section h3 {
  color: var(--text-color-light);
}

.page-cockfighting__dark-section .page-cockfighting__section-description,
.page-cockfighting__dark-section p {
  color: var(--text-color-light);
  opacity: 0.9;
}

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

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

.page-cockfighting__feature-item {
  background: var(--secondary-color);
  padding: var(--spacing-medium);
  border-radius: var(--border-radius-default);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
  transition: transform 0.3s ease;
}

.page-cockfighting__feature-item:hover {
  transform: translateY(-5px);
}

.page-cockfighting__feature-item img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
  margin-bottom: 20px;
  object-fit: cover;
  min-width: 200px; /* Enforce min size */
  min-height: 200px; /* Enforce min size */
}

.page-cockfighting__feature-item h3 {
  font-size: 1.5em;
  margin-bottom: 10px;
  color: var(--primary-color);
}

.page-cockfighting__feature-item p {
  font-size: 1em;
  color: var(--text-color-dark);
}

/* Cards Grid (Game Types) */
.page-cockfighting__cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-cockfighting__card {
  background: var(--secondary-color);
  padding: var(--spacing-small);
  border-radius: var(--border-radius-default);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  color: var(--text-color-dark);
}

.page-cockfighting__card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.page-cockfighting__card img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
  margin-bottom: 20px;
  object-fit: cover;
  min-width: 200px; /* Enforce min size */
  min-height: 200px; /* Enforce min size */
}

.page-cockfighting__card h3 {
  font-size: 1.6em;
  margin-bottom: 15px;
  color: var(--primary-color);
}

.page-cockfighting__card p {
  font-size: 1em;
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-cockfighting__btn-primary {
  display: inline-block;
  padding: 10px 25px;
  background: var(--primary-color);
  color: var(--text-color-light);
  text-decoration: none;
  border-radius: 5px;
  font-weight: bold;
  transition: background-color 0.3s ease, transform 0.3s ease;
  border: 2px solid var(--primary-color);
  box-sizing: border-box;
  max-width: 100%;
  white-space: normal;
  word-wrap: break-word;
}

.page-cockfighting__btn-primary:hover {
  background: #005c2b; /* Darker shade of #017439 */
  transform: translateY(-1px);
}

.page-cockfighting__btn-secondary {
  display: inline-block;
  padding: 10px 25px;
  background: var(--secondary-color);
  color: var(--primary-color);
  text-decoration: none;
  border-radius: 5px;
  font-weight: bold;
  transition: background-color 0.3s ease, transform 0.3s ease, color 0.3s ease;
  border: 2px solid var(--primary-color);
  box-sizing: border-box;
  max-width: 100%;
  white-space: normal;
  word-wrap: break-word;
}

.page-cockfighting__btn-secondary:hover {
  background: var(--primary-color);
  color: var(--text-color-light);
  transform: translateY(-1px);
}

/* How-To Steps */
.page-cockfighting__steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-cockfighting__step-item {
  background: var(--secondary-color);
  padding: var(--spacing-medium);
  border-radius: var(--border-radius-default);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  text-align: center;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  min-height: 280px; /* Ensure consistent height */
}

.page-cockfighting__step-number {
  background: var(--primary-color);
  color: var(--text-color-light);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8em;
  font-weight: bold;
  margin-bottom: 20px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.page-cockfighting__step-item h3 {
  font-size: 1.5em;
  margin-bottom: 10px;
  color: var(--primary-color);
}

.page-cockfighting__step-item p {
  font-size: 1em;
  margin-bottom: 20px;
  flex-grow: 1;
}

/* Tips Section */
.page-cockfighting__content-wrapper {
  display: flex;
  gap: 40px;
  align-items: flex-start;
  margin-top: 40px;
  text-align: left;
}

.page-cockfighting__text-block {
  flex: 2;
}

.page-cockfighting__text-block h3 {
  font-size: 1.6em;
  margin-top: 25px;
  margin-bottom: 15px;
  color: var(--text-color-light);
}

.page-cockfighting__text-block p {
  margin-bottom: 15px;
  color: var(--text-color-light);
  opacity: 0.9;
}

.page-cockfighting__image-block {
  flex: 1;
  min-width: 300px;
  max-width: 500px;
}

.page-cockfighting__image-block img {
  max-width: 100%;
  height: auto;
  border-radius: var(--border-radius-default);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  object-fit: cover;
  min-width: 200px; /* Enforce min size */
  min-height: 200px; /* Enforce min size */
}

/* FAQ Section */
.page-cockfighting__faq-list {
  margin-top: 40px;
  text-align: left;
}

.page-cockfighting__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
}

.page-cockfighting__faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease, opacity 0.4s ease;
  padding: 0 15px;
  opacity: 0;
  color: var(--text-color-dark);
}

.page-cockfighting__faq-item.active .page-cockfighting__faq-answer {
  max-height: 2000px !important;
  padding: 20px 15px !important;
  opacity: 1;
  background: #f9f9f9;
  border-radius: 0 0 5px 5px;
}