/* style/lottery.css */
:root {
    --primary-color: #0047AB;
    --secondary-color: #FFD700;
    --text-color-dark-bg: #ffffff;
    --text-color-light-bg: #333333;
    --card-bg-dark-mode: rgba(255, 255, 255, 0.1);
    --card-bg-light-mode: #ffffff;
    --border-color: #e0e0e0;
    --hover-color-primary: #003380;
    --hover-color-secondary: #e6c200;
}

.page-lottery {
    font-family: 'Arial', sans-serif;
    color: var(--text-color-dark-bg); /* Body background is dark, so text should be light */
    line-height: 1.6;
    padding-top: 10px; /* Base padding for fixed header */
}

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

.page-lottery__dark-section {
    background: var(--primary-color);
    color: var(--text-color-dark-bg);
    padding: 60px 0;
}

.page-lottery__hero-section {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 20px 40px;
    background: linear-gradient(135deg, var(--primary-color) 0%, #002255 100%);
    color: var(--text-color-dark-bg);
    text-align: center;
    overflow: hidden;
    padding-top: 10px; /* Specific padding for hero to avoid header overlap */
}

.page-lottery__hero-container {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 0 auto;
}

.page-lottery__main-title {
    font-size: 48px;
    font-weight: bold;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.page-lottery__hero-description {
    font-size: 20px;
    margin-bottom: 40px;
    line-height: 1.8;
}

.page-lottery__cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.page-lottery__cta-button {
    display: inline-block;
    padding: 15px 35px;
    border-radius: 8px;
    font-size: 18px;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    border: none;
    cursor: pointer;
    white-space: nowrap;
    word-wrap: normal;
}

.page-lottery__cta-button--primary {
    background: var(--secondary-color);
    color: var(--text-color-light-bg);
}

.page-lottery__cta-button--primary:hover {
    background: var(--hover-color-secondary);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

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

.page-lottery__cta-button--secondary:hover {
    background: var(--secondary-color);
    color: var(--text-color-light-bg);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.page-lottery__cta-button--center {
    margin-top: 30px;
    display: flex;
    justify-content: center;
    width: 100%;
}

.page-lottery__hero-image {
    width: 100%;
    max-width: 800px;
    height: auto;
    margin-top: 30px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.page-lottery__section-title {
    font-size: 38px;
    font-weight: bold;
    text-align: center;
    margin-bottom: 40px;
    color: var(--text-color-dark-bg);
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.2);
}

.page-lottery__introduction-section, .page-lottery__benefits-section, .page-lottery__tips-section, .page-lottery__faq-section {
    padding: 60px 0;
    background: #1a1a1a;
    color: var(--text-color-dark-bg);
}

.page-lottery__types-section, .page-lottery__guide-section, .page-lottery__promotions-section, .page-lottery__news-section {
    padding: 60px 0;
    background: #2a2a2a;
    color: var(--text-color-dark-bg);
}

.page-lottery__text-block {
    font-size: 18px;
    line-height: 1.8;
    margin-bottom: 20px;
    text-align: justify;
}

.page-lottery__content-image {
    width: 100%;
    max-width: 700px;
    height: auto;
    display: block;
    margin: 40px auto;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

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

.page-lottery__grid--two-columns {
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
}

.page-lottery__card {
    background: var(--card-bg-dark-mode);
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    color: var(--text-color-dark-bg);
}

.page-lottery__card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

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

.page-lottery__card-title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 15px;
    color: var(--secondary-color);
}

.page-lottery__card-description {
    font-size: 16px;
    line-height: 1.7;
    margin-bottom: 20px;
    flex-grow: 1;
}

.page-lottery__card-button {
    display: inline-block;
    padding: 12px 25px;
    background: var(--secondary-color);
    color: var(--text-color-light-bg);
    text-decoration: none;
    border-radius: 6px;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.page-lottery__card-button:hover {
    background: var(--hover-color-secondary);
}

.page-lottery__card--no-image {
    padding-top: 40px;
    padding-bottom: 40px;
}

.page-lottery__benefit-list {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

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

.page-lottery__benefit-item:hover {
    transform: translateY(-3px);
}

.page-lottery__benefit-title {
    font-size: 22px;
    font-weight: bold;
    color: var(--secondary-color);
    margin-bottom: 10px;
}

.page-lottery__benefit-description {
    font-size: 16px;
    line-height: 1.7;
}

.page-lottery__guide-list {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
}

.page-lottery__guide-item {
    background: var(--card-bg-dark-mode);
    border-left: 5px solid var(--secondary-color);
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.2);
}

.page-lottery__guide-title {
    font-size: 22px;
    font-weight: bold;
    color: var(--text-color-dark-bg);
    margin-bottom: 10px;
}

.page-lottery__guide-description {
    font-size: 16px;
    line-height: 1.7;
}

.page-lottery__promotion-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.page-lottery__promotion-card {
    background: var(--card-bg-dark-mode);
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--text-color-dark-bg);
}

.page-lottery__promotion-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.page-lottery__promotion-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 20px;
    display: block;
}

.page-lottery__promotion-title {
    font-size: 24px;
    font-weight: bold;
    color: var(--secondary-color);
    margin-bottom: 15px;
}

.page-lottery__promotion-description {
    font-size: 16px;
    line-height: 1.7;
    margin-bottom: 20px;
    flex-grow: 1;
}

.page-lottery__promotion-button {
    display: inline-block;
    padding: 12px 25px;
    background: var(--primary-color);
    color: var(--text-color-dark-bg);
    text-decoration: none;
    border-radius: 6px;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.page-lottery__promotion-button:hover {
    background: var(--hover-color-primary);
}

/* FAQ Styles */
.page-lottery__faq-list {
    max-width: 900px;
    margin: 0 auto;
}

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

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

.page-lottery__faq-item.active .page-lottery__faq-answer {
  max-height: 2000px !important;
  padding: 20px 15px !important;
  opacity: 1;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 0 0 5px 5px;
}

.page-lottery__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 5px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
  color: var(--text-color-dark-bg);
}

.page-lottery__faq-question:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.3);
}

.page-lottery__faq-question:active {
  background: rgba(255, 255, 255, 0.25);
}

.page-lottery__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  pointer-events: none;
}

.page-lottery__faq-toggle {
  font-size: 28px;
  font-weight: bold;
  line-height: 1;
  color: var(--secondary-color);
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
}

.page-lottery__faq-item.active .page-lottery__faq-toggle {
  color: var(--text-color-dark-bg);
  transform: rotate(180deg);
}

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

.page-lottery__blog-item {
    background: var(--card-bg-dark-mode);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-lottery__blog-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.page-lottery__blog-link {
    display: block;
    text-decoration: none;
    color: var(--text-color-dark-bg);
    padding: 20px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.page-lottery__blog-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 20px;
    display: block;
}

.page-lottery__blog-item-title {
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 10px;
    color: var(--secondary-color);
}

.page-lottery__blog-item-excerpt {
    font-size: 16px;
    line-height: 1.7;
    margin-bottom: 15px;
    flex-grow: 1;
}

.page-lottery__blog-item-date {
    font-size: 14px;
    color: #cccccc;
}

.page-lottery__inline-link {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.page-lottery__inline-link:hover {
    color: var(--hover-color-secondary);
    text-decoration: underline;
}

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

    .page-lottery__hero-description {
        font-size: 18px;
    }

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

    .page-lottery__grid--two-columns {
        grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    }
}

@media (max-width: 768px) {
    .page-lottery {
        padding-top: 10px !important; /* Mobile padding for fixed header */
        font-size: 16px;
        line-height: 1.6;
    }

    .page-lottery__container {
        padding: 0 15px;
    }

    .page-lottery__hero-section {
        padding: 60px 15px 30px;
        padding-top: 10px !important; /* Mobile specific padding for hero */
    }

    .page-lottery__main-title {
        font-size: 36px;
        margin-bottom: 15px;
    }

    .page-lottery__hero-description {
        font-size: 16px;
        margin-bottom: 30px;
    }

    .page-lottery__cta-buttons {
        flex-direction: column;
        gap: 15px;
        margin-bottom: 30px;
        width: 100%;
    }

    .page-lottery__cta-button {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        padding: 12px 25px !important;
        font-size: 16px !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

    .page-lottery__hero-image,
    .page-lottery__content-image {
        margin-top: 20px;
        border-radius: 8px;
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }

    .page-lottery__section-title {
        font-size: 28px;
        margin-bottom: 30px;
    }

    .page-lottery__text-block {
        font-size: 16px;
    }

    .page-lottery__grid,
    .page-lottery__grid--two-columns,
    .page-lottery__benefit-list,
    .page-lottery__promotion-grid,
    .page-lottery__blog-list {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-lottery__card,
    .page-lottery__benefit-item,
    .page-lottery__guide-item,
    .page-lottery__promotion-card,
    .page-lottery__blog-item {
        padding: 20px;
        border-radius: 8px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    .page-lottery__card-image,
    .page-lottery__promotion-image,
    .page-lottery__blog-image {
        height: 180px;
        border-radius: 6px;
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }

    .page-lottery__card-title,
    .page-lottery__benefit-title,
    .page-lottery__guide-title,
    .page-lottery__promotion-title,
    .page-lottery__blog-item-title {
        font-size: 20px;
    }

    .page-lottery__card-description,
    .page-lottery__benefit-description,
    .page-lottery__guide-description,
    .page-lottery__promotion-description,
    .page-lottery__blog-item-excerpt {
        font-size: 15px;
    }

    .page-lottery__card-button,
    .page-lottery__promotion-button {
        padding: 10px 20px;
        font-size: 15px;
    }

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