/* style/cockfighting.css */

:root {
    --primary-color: #017439;
    --secondary-color: #FFFFFF;
    --text-color-dark: #333333;
    --text-color-light: #ffffff;
    --background-color-light: #f5f5f5;
    --background-color-white: #ffffff;
    --button-register-bg: #C30808;
    --button-register-text: #FFFF00;
    --button-login-bg: #C30808;
    --button-login-text: #FFFF00;
}

.page-cockfighting {
    font-family: 'Arial', sans-serif;
    color: var(--text-color-dark);
    background-color: var(--background-color-white);
    line-height: 1.6;
    padding-top: var(--header-offset, 120px);
}

/* Hero Section */
.page-cockfighting__hero-section {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 60px 20px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--text-color-light);
    overflow: hidden;
}

.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: 30px;
    border-radius: 8px;
    overflow: hidden;
}

.page-cockfighting__hero-image img {
    width: 100%;
    height: auto;
    max-width: 100%;
    display: block;
    object-fit: cover;
}

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

.page-cockfighting__hero-title {
    font-size: 3.2em;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--secondary-color);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.page-cockfighting__hero-description {
    font-size: 1.3em;
    margin-bottom: 40px;
    color: var(--secondary-color);
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.4);
}

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

.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;
    border: none;
    cursor: pointer;
}

.page-cockfighting__btn-register {
    background: var(--button-register-bg);
    color: var(--button-register-text);
}

.page-cockfighting__btn-register:hover {
    background: darken(var(--button-register-bg), 10%); /* Placeholder for darker color */
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.page-cockfighting__btn-login {
    background: var(--button-login-bg);
    color: var(--button-login-text);
}

.page-cockfighting__btn-login:hover {
    background: darken(var(--button-login-bg), 10%); /* Placeholder for darker color */
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* General Section Styling */
.page-cockfighting__section {
    padding: 80px 20px;
    text-align: center;
}

.page-cockfighting__section:nth-of-type(even) {
    background-color: var(--background-color-light);
}

.page-cockfighting__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.page-cockfighting__section-title {
    font-size: 2.5em;
    color: var(--primary-color);
    margin-bottom: 40px;
    position: relative;
    padding-bottom: 15px;
}

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

.page-cockfighting__text-block {
    font-size: 1.1em;
    margin-bottom: 20px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    text-align: left;
}

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

/* Features Grid */
.page-cockfighting__features-grid,
.page-cockfighting__type-grid,
.page-cockfighting__news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 40px;
    text-align: left;
}

.page-cockfighting__feature-card,
.page-cockfighting__type-card,
.page-cockfighting__news-card {
    background-color: var(--background-color-white);
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding-bottom: 20px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.page-cockfighting__feature-card:hover,
.page-cockfighting__type-card:hover,
.page-cockfighting__news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.page-cockfighting__feature-card img,
.page-cockfighting__type-card img,
.page-cockfighting__news-card img {
    width: 100%;
    height: 250px; /* Fixed height for cards */
    object-fit: cover;
    border-radius: 10px 10px 0 0;
    margin-bottom: 15px;
}

.page-cockfighting__card-title {
    font-size: 1.5em;
    color: var(--primary-color);
    margin: 0 20px 10px;
}

.page-cockfighting__feature-card p,
.page-cockfighting__type-card p,
.page-cockfighting__news-excerpt {
    font-size: 1em;
    color: var(--text-color-dark);
    margin: 0 20px 15px;
}

/* Betting Strategies List */
.page-cockfighting__strategy-list {
    list-style: none;
    padding: 0;
    margin-top: 30px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    text-align: left;
}

.page-cockfighting__strategy-list li {
    background-color: var(--background-color-white);
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 15px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    font-size: 1.1em;
    color: var(--text-color-dark);
}

.page-cockfighting__strategy-list li strong {
    color: var(--primary-color);
}

/* FAQ Section */
.page-cockfighting__faq-area {
    background-color: var(--background-color-light);
}

.page-cockfighting__faq-list {
    max-width: 900px;
    margin: 0 auto;
    text-align: left;
}

/* FAQ容器样式 */
.page-cockfighting__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
}

/* FAQ默认状态 - 答案隐藏 */
.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;
}

/* FAQ展开状态 - 🚨 使用!important và đủ lớn max-height để đảm bảo có thể mở rộng */
.page-cockfighting__faq-item.active .page-cockfighting__faq-answer {
  max-height: 2000px !important; /* 🚨 Sử dụng !important để đảm bảo ưu tiên, giá trị đủ lớn để chứa mọi nội dung */
  padding: 20px 15px !important;
  opacity: 1;
  background: #f9f9f9;
  border-radius: 0 0 5px 5px;
}

/* Question style */
.page-cockfighting__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 5px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
}

.page-cockfighting__faq-question:hover {
  background: #f5f5f5;
  border-color: #d0d0d0;
}

.page-cockfighting__faq-question:active {
  background: #eeeeee;
}

/* Question title style */
.page-cockfighting__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.5;
  pointer-events: none; /* Ngăn chặn thẻ h3 chặn sự kiện click */
}

/* Toggle icon */
.page-cockfighting__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  line-height: 1;
  color: var(--primary-color);
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none; /* Ngăn chặn biểu tượng chặn sự kiện click */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
}

.page-cockfighting__faq-item.active .page-cockfighting__faq-toggle {
  transform: rotate(45deg);
  color: var(--primary-color);
}

/* Latest News Section */
.page-cockfighting__news-card img {
    height: 200px; /* Adjusted height for news cards */
}

.page-cockfighting__news-link {
    text-decoration: none;
    color: var(--primary-color);
    transition: color 0.3s ease;
}

.page-cockfighting__news-link:hover {
    color: darken(var(--primary-color), 10%); /* Placeholder for darker color */
}

.page-cockfighting__news-date {
    display: block;
    font-size: 0.9em;
    color: #666;
    margin: 10px 20px 0;
}

.page-cockfighting__view-all-news {
    margin-top: 50px;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-cockfighting__hero-title {
        font-size: 2.5em;
    }
    .page-cockfighting__hero-description {
        font-size: 1.1em;
    }
    .page-cockfighting__section-title {
        font-size: 2em;
    }
}

@media (max-width: 768px) {
    .page-cockfighting {
        padding-top: var(--header-offset, 120px) !important;
        font-size: 16px;
        line-height: 1.6;
    }
    
    .page-cockfighting__hero-section {
        padding-top: var(--header-offset, 120px) !important;
        padding-bottom: 40px;
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .page-cockfighting__hero-title {
        font-size: 2em;
        margin-bottom: 15px;
    }
    
    .page-cockfighting__hero-description {
        font-size: 1em;
        margin-bottom: 30px;
    }
    
    .page-cockfighting__hero-buttons {
        flex-direction: column;
        gap: 15px;
        width: 100%;
    }

    .page-cockfighting__cta-button,
    .page-cockfighting__btn-register,
    .page-cockfighting__btn-login,
    .page-cockfighting a[class*="button"],
    .page-cockfighting 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-cockfighting__hero-image img,
    .page-cockfighting__image-responsive,
    .page-cockfighting img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
    }
    
    .page-cockfighting__section,
    .page-cockfighting__card,
    .page-cockfighting__container,
    .page-cockfighting__cta-buttons,
    .page-cockfighting__button-group,
    .page-cockfighting__btn-container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .page-cockfighting__section {
        padding: 40px 0;
    }
    
    .page-cockfighting__section-title {
        font-size: 1.8em;
        margin-bottom: 30px;
    }
    
    .page-cockfighting__feature-card img,
    .page-cockfighting__type-card img,
    .page-cockfighting__news-card img {
        
    }

    .page-cockfighting__faq-question {
      padding: 15px;
      flex-wrap: wrap;
    }
    
    .page-cockfighting__faq-question h3 {
      font-size: 15px;
      margin-bottom: 0;
      width: calc(100% - 40px);
    }
    
    .page-cockfighting__faq-toggle {
      margin-left: 10px;
      width: 24px;
      height: 24px;
      font-size: 20px;
    }
    
    .page-cockfighting__faq-answer {
      padding: 0 15px;
    }
    
    .page-cockfighting__faq-item.active .page-cockfighting__faq-answer {
      padding: 15px !important;
    }
}

@media (max-width: 480px) {
    .page-cockfighting__hero-title {
        font-size: 1.8em;
    }
    .page-cockfighting__hero-description {
        font-size: 0.9em;
    }
    .page-cockfighting__cta-button {
        padding: 12px 25px;
        font-size: 16px;
    }
    .page-cockfighting__section-title {
        font-size: 1.5em;
    }
    .page-cockfighting__text-block {
        font-size: 1em;
    }
    .page-cockfighting__feature-card img,
    .page-cockfighting__type-card img,
    .page-cockfighting__news-card img {
        
    }
}