/* style/cockfighting.css */

/* Base styles for the cockfighting page */
.page-cockfighting {
    font-family: 'Arial', sans-serif;
    color: #333333; /* Dark text for light body background #FFFFFF */
    line-height: 1.6;
    background-color: #FFFFFF; /* Ensure consistency with body background */
}

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

.page-cockfighting__section-title {
    font-size: 36px;
    font-weight: bold;
    color: #017439; /* Brand primary color */
    text-align: center;
    margin-bottom: 40px;
    position: relative;
    padding-bottom: 15px;
}

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

.page-cockfighting__section-title--white {
    color: #FFFFFF;
}

.page-cockfighting__section-title--white::after {
    background-color: #FFFFFF;
}

.page-cockfighting__intro-text {
    font-size: 18px;
    text-align: center;
    max-width: 900px;
    margin: 0 auto 50px auto;
    color: #555555;
}

.page-cockfighting__intro-text--white {
    color: #f0f0f0;
}

.page-cockfighting__cta-button {
    display: inline-block;
    padding: 15px 40px;
    text-align: center;
    text-decoration: none;
    border-radius: 8px;
    font-size: 18px;
    font-weight: bold;
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.page-cockfighting__cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
}

.page-cockfighting__btn-primary {
    background: #017439; /* Brand primary color */
    color: #FFFFFF;
    border: 2px solid #017439;
}

.page-cockfighting__btn-primary:hover {
    background: #005f2c;
    border-color: #005f2c;
}

.page-cockfighting__btn-secondary {
    background: #FFFFFF;
    color: #017439; /* Brand primary color */
    border: 2px solid #017439;
}

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

.page-cockfighting__btn-register {
    background: #C30808; /* Custom red for register */
    color: #FFFF00; /* Custom yellow for register text */
    border: 2px solid #C30808;
}

.page-cockfighting__btn-register:hover {
    background: #a50707;
    border-color: #a50707;
}

.page-cockfighting__btn-login {
    background: #C30808; /* Custom red for login */
    color: #FFFF00; /* Custom yellow for login text */
    border: 2px solid #C30808;
    margin-left: 15px;
}

.page-cockfighting__btn-login:hover {
    background: #a50707;
    border-color: #a50707;
}

.page-cockfighting__cta-center {
    text-align: center;
    margin-top: 50px;
}

.page-cockfighting__text-center {
    text-align: center;
    margin-top: 30px;
}

.page-cockfighting__text-center a {
    color: #017439;
    text-decoration: underline;
}

/* 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;
    padding-top: var(--header-offset, 120px); /* Fixed header offset */
    background: linear-gradient(135deg, #017439, #005f2c); /* Darker gradient for hero background */
    color: #FFFFFF;
}

.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;
}

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

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

.page-cockfighting__main-title {
    font-size: 48px;
    margin-bottom: 20px;
    line-height: 1.2;
    color: #FFFFFF;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
}

.page-cockfighting__intro-text {
    font-size: 20px;
    max-width: 800px;
    margin: 0 auto 40px auto;
    color: #f0f0f0;
}

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

/* About Section */
.page-cockfighting__about-section {
    padding: 80px 0;
    background-color: #FFFFFF;
}

.page-cockfighting__about-section p {
    margin-bottom: 20px;
    font-size: 17px;
    text-align: justify;
}

.page-cockfighting__image-content {
    display: block;
    margin: 40px auto;
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.page-cockfighting__image-content--large {
    max-width: 80%;
}

/* Why Choose Section */
.page-cockfighting__why-choose-section {
    padding: 80px 0;
    background-color: #017439; /* Brand primary color */
    color: #FFFFFF;
}

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

.page-cockfighting__feature-item {
    background: rgba(255, 255, 255, 0.1); /* Slightly transparent white for contrast */
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    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: 5px;
    margin-bottom: 20px;
    object-fit: cover;
    min-width: 200px; /* Enforce minimum image size */
    min-height: 200px;
}

.page-cockfighting__feature-title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 15px;
    color: #FFFFFF;
}

.page-cockfighting__feature-description {
    font-size: 16px;
    color: #f0f0f0;
}

/* Betting Types Section */
.page-cockfighting__betting-types-section {
    padding: 80px 0;
    background-color: #f9f9f9;
}

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

.page-cockfighting__betting-card {
    background: #FFFFFF;
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.page-cockfighting__betting-card:hover {
    transform: translateY(-5px);
}

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

.page-cockfighting__betting-card-title {
    font-size: 24px;
    font-weight: bold;
    color: #017439;
    margin-bottom: 15px;
}

/* Strategy Section */
.page-cockfighting__strategy-section {
    padding: 80px 0;
    background-color: #017439;
    color: #FFFFFF;
}

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

.page-cockfighting__strategy-item {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

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

.page-cockfighting__strategy-item-title {
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 15px;
    color: #FFFFFF;
}

.page-cockfighting__strategy-item-description {
    font-size: 16px;
    color: #f0f0f0;
}

/* Promotions Section */
.page-cockfighting__promotions-section {
    padding: 80px 0;
    background-color: #FFFFFF;
}

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

.page-cockfighting__promotion-card {
    background: #f9f9f9;
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.page-cockfighting__promotion-card:hover {
    transform: translateY(-5px);
}

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

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

.page-cockfighting__promotion-card .page-cockfighting__cta-button {
    margin-top: 20px;
    padding: 10px 25px;
    font-size: 16px;
}


/* FAQ Section */
.page-cockfighting__faq-section {
    padding: 80px 0;
    background-color: #f0f0f0;
}

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

/* 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;
  padding: 0 15px;
  opacity: 0;
}

/* FAQ展开状态 - ⚠️ 使用!important và đủ lớn max-height để đảm bảo 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;
  color: #333333; /* Ensure dark text on light background */
}

/* Question styles */
.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 styles */
.page-cockfighting__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.5;
  pointer-events: none; /* Prevent h3 from blocking click event */
  color: #017439; /* Ensure good contrast for question title */
}

/* Toggle icon */
.page-cockfighting__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  line-height: 1;
  color: #666;
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none; /* Prevent icon from blocking click event */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
}

.page-cockfighting__faq-item.active .page-cockfighting__faq-toggle {
  color: #333;
}

/* News Section */
.page-cockfighting__news-section {
    padding: 80px 0;
    background-color: #017439;
    color: #FFFFFF;
}

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

.page-cockfighting__news-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.page-cockfighting__news-card:hover {
    transform: translateY(-5px);
}

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

.page-cockfighting__news-title {
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 10px;
    color: #FFFFFF;
}

.page-cockfighting__news-title a {
    color: #FFFFFF;
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-cockfighting__news-title a:hover {
    color: #FFFF00; /* Custom yellow for hover */
}

.page-cockfighting__news-excerpt {
    font-size: 16px;
    color: #f0f0f0;
    margin-bottom: 20px;
}

.page-cockfighting__read-more {
    display: inline-block;
    color: #FFFF00; /* Custom yellow for read more */
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.page-cockfighting__read-more:hover {
    color: #FFFFFF;
    text-decoration: underline;
}

.page-cockfighting__read-more--white {
    color: #FFFFFF;
}

.page-cockfighting__read-more--white:hover {
    color: #FFFF00;
}

/* Global image styles to prevent small icons */
.page-cockfighting img {
    min-width: 200px;
    min-height: 200px;
    object-fit: cover; /* Ensure images cover their area without distortion */
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-cockfighting__main-title {
        font-size: 40px;
    }
    .page-cockfighting__section-title {
        font-size: 30px;
    }
    .page-cockfighting__intro-text {
        font-size: 18px;
    }
}

@media (max-width: 768px) {
    /* Mobile header offset and general padding */
    .page-cockfighting__hero-section {
        padding-top: var(--header-offset, 120px) !important;
        padding-bottom: 40px;
        padding-left: 15px;
        padding-right: 15px;
    }

    /* General content padding */
    .page-cockfighting__container {
        padding: 15px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .page-cockfighting__main-title {
        font-size: 32px;
    }

    .page-cockfighting__section-title {
        font-size: 26px;
        margin-bottom: 30px;
    }

    .page-cockfighting__intro-text {
        font-size: 16px;
        margin-bottom: 30px;
    }

    /* Buttons */
    .page-cockfighting__cta-buttons {
        flex-direction: column;
        gap: 10px;
    }

    .page-cockfighting__cta-button,
    .page-cockfighting__btn-primary,
    .page-cockfighting__btn-secondary,
    .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__btn-login {
        margin-left: 0; /* Remove margin for stacked buttons */
    }

    /* Image responsiveness */
    .page-cockfighting img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        min-width: unset !important; /* Allow smaller display sizes on mobile if needed, but still >= 200px for generation */
        min-height: unset !important;
    }

    .page-cockfighting__image-content--large {
        max-width: 100%;
    }

    /* Card and grid layouts */
    .page-cockfighting__features-grid,
    .page-cockfighting__betting-grid,
    .page-cockfighting__strategy-list,
    .page-cockfighting__promotions-grid,
    .page-cockfighting__news-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-cockfighting__feature-item,
    .page-cockfighting__betting-card,
    .page-cockfighting__strategy-item,
    .page-cockfighting__promotion-card,
    .page-cockfighting__news-card {
        padding: 20px;
    }

    .page-cockfighting__feature-item img,
    .page-cockfighting__betting-card img,
    .page-cockfighting__promotion-card img,
    .page-cockfighting__news-card img {
        min-width: 200px; /* Still enforce minimum size for generated images */
        min-height: 200px;
    }

    /* FAQ Mobile */
    .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;
    }
}