/* style/gdpr.css */

/* Base styles for the GDPR page */
.page-gdpr {
    font-family: 'Arial', sans-serif;
    color: #ffffff; /* Light text for dark body background */
    background-color: transparent; /* Body background from shared.css (#000) */
    line-height: 1.6;
}

/* Hero Section */
.page-gdpr__hero-section {
    position: relative;
    padding: 80px 20px 60px;
    background: linear-gradient(135deg, #4A148C, #6A1B9A); /* Dark purple gradient */
    text-align: center;
    color: #ffffff;
    padding-top: 0; /* Assuming shared.css handles body padding-top for header offset */
}

.page-gdpr__hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding-top: var(--header-offset, 120px); /* This handles the header offset if body doesn't */
}

.page-gdpr__main-title {
    font-size: 3.2em;
    margin-bottom: 20px;
    color: #FFD700; /* Auxiliary color for emphasis */
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    font-weight: 700;
    line-height: 1.2;
}

.page-gdpr__intro-description {
    font-size: 1.2em;
    max-width: 800px;
    margin: 0 auto 30px;
    color: #f0f0f0;
}

/* Content Sections */
.page-gdpr__content-section {
    padding: 60px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.page-gdpr__content-section:last-of-type {
    border-bottom: none;
}

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

.page-gdpr__section-title {
    font-size: 2.5em;
    color: #FFD700; /* Auxiliary color */
    margin-bottom: 30px;
    text-align: center;
    font-weight: 700;
}

.page-gdpr__text-block {
    font-size: 1.1em;
    margin-bottom: 20px;
    color: #e0e0e0;
}

.page-gdpr__list {
    list-style: none;
    padding: 0;
    margin-bottom: 20px;
}

.page-gdpr__list-item {
    font-size: 1.1em;
    margin-bottom: 10px;
    position: relative;
    padding-left: 25px;
    color: #e0e0e0;
}

.page-gdpr__list-item::before {
    content: '•';
    color: #FFD700; /* Auxiliary color for bullet points */
    position: absolute;
    left: 0;
    font-weight: bold;
    font-size: 1.2em;
    line-height: 1.2;
}

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

.page-gdpr__list--inline .page-gdpr__list-item {
    padding-left: 0;
    margin-bottom: 0;
}

.page-gdpr__list--inline .page-gdpr__list-item::before {
    content: none;
}

.page-gdpr__link {
    color: #FFD700;
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-gdpr__link:hover {
    color: #fff;
    text-decoration: underline;
}

/* Images within content */
.page-gdpr__image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 30px auto;
    display: block;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    object-fit: cover;
    min-width: 200px;
    min-height: 200px;
}

.page-gdpr__image--right {
    float: right;
    margin-left: 30px;
    margin-bottom: 20px;
    width: 45%; /* Adjust width for text wrapping */
    max-width: 600px;
}

.page-gdpr__image--left {
    float: left;
    margin-right: 30px;
    margin-bottom: 20px;
    width: 45%; /* Adjust width for text wrapping */
    max-width: 600px;
}

/* Clear floats for images */
.page-gdpr__content-section::after {
    content: "";
    display: table;
    clear: both;
}

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

.page-gdpr__right-card {
    background: rgba(74, 20, 140, 0.7); /* Main color with transparency */
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    transition: transform 0.3s ease, background-color 0.3s ease;
    min-height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.page-gdpr__right-card:hover {
    transform: translateY(-8px);
    background: #4A148C;
}

.page-gdpr__card-title {
    font-size: 1.5em;
    color: #FFD700;
    margin-top: 0;
    margin-bottom: 15px;
    font-weight: 600;
}

.page-gdpr__card-description {
    font-size: 1em;
    color: #e0e0e0;
}

/* DPO Contact Info */
.page-gdpr__contact-info {
    background: rgba(74, 20, 140, 0.7);
    padding: 30px;
    border-radius: 12px;
    margin-top: 30px;
    margin-bottom: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    text-align: center;
}

.page-gdpr__contact-item {
    font-size: 1.1em;
    margin-bottom: 15px;
    color: #ffffff;
}

.page-gdpr__contact-item:last-child {
    margin-bottom: 0;
}

.page-gdpr__contact-link {
    color: #FFD700;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.page-gdpr__contact-link:hover {
    color: #fff;
    text-decoration: underline;
}

/* FAQ Section */
.page-gdpr__faq-section {
    padding: 60px 20px;
}

/* FAQ容器样式 */
.page-gdpr__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
  background: rgba(74, 20, 140, 0.7); /* Darker background for FAQ items */
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

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

/* FAQ展开状态 - 🚨 使用!important和足够大的max-height确保一定能展开 */
.page-gdpr__faq-item.active .page-gdpr__faq-answer {
  max-height: 2000px !important; /* 🚨 使用!important确保优先级，值足够大以容纳任何内容 */
  padding: 20px 15px !important;
  opacity: 1;
  background: rgba(74, 20, 140, 0.9); /* Slightly darker when active */
  border-radius: 0 0 5px 5px;
}

/* 问题样式 */
.page-gdpr__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: #4A148C; /* Main color */
  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: #ffffff;
}

.page-gdpr__faq-question:hover {
  background: #5A249C; /* Slightly lighter on hover */
  border-color: rgba(255, 255, 255, 0.3);
}

.page-gdpr__faq-question:active {
  background: #3A0F7C;
}

/* 问题标题样式 */
.page-gdpr__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 1.2em;
  font-weight: 600;
  line-height: 1.5;
  pointer-events: none; /* 防止h3标签阻止点击事件 */
  color: #FFD700; /* Auxiliary color for question text */
}

/* 切换图标 */
.page-gdpr__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  line-height: 1;
  color: #FFD700;
  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: 28px;
  height: 28px;
}

.page-gdpr__faq-item.active .page-gdpr__faq-toggle {
  color: #ffffff;
  transform: rotate(45deg); /* Rotate for minus sign effect */
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-gdpr__main-title {
        font-size: 2.8em;
    }
    .page-gdpr__section-title {
        font-size: 2em;
    }
    .page-gdpr__image--right,
    .page-gdpr__image--left {
        width: 100%;
        float: none;
        margin: 30px auto;
    }
    .page-gdpr__text-block {
        clear: both;
    }
}

@media (max-width: 768px) {
    /* General mobile adaptations */
    .page-gdpr {
        font-size: 16px;
        line-height: 1.6;
    }

    .page-gdpr__hero-section {
        padding: 40px 15px;
        padding-top: var(--header-offset-mobile, 80px);
    }

    .page-gdpr__main-title {
        font-size: 2em;
        margin-bottom: 15px;
        line-height: 1.3;
    }

    .page-gdpr__intro-description {
        font-size: 1em;
        margin-bottom: 20px;
    }

    .page-gdpr__content-section {
        padding: 40px 15px;
    }

    .page-gdpr__section-title {
        font-size: 1.8em;
        margin-bottom: 25px;
    }

    .page-gdpr__text-block,
    .page-gdpr__list-item,
    .page-gdpr__card-description {
        font-size: 0.95em;
    }

    /* Images mobile adaptation */
    .page-gdpr img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        min-width: unset;
        min-height: unset;
    }

    .page-gdpr__image--right,
    .page-gdpr__image--left {
        width: 100%;
        float: none;
        margin: 20px auto;
    }

    /* User Rights Grid mobile adaptation */
    .page-gdpr__rights-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-gdpr__right-card {
        padding: 25px;
        min-height: unset;
    }

    .page-gdpr__card-title {
        font-size: 1.3em;
        margin-bottom: 10px;
    }

    /* DPO Contact Info mobile adaptation */
    .page-gdpr__contact-info {
        padding: 25px;
        margin-top: 25px;
        margin-bottom: 25px;
    }

    .page-gdpr__contact-item {
        font-size: 1em;
        margin-bottom: 10px;
    }

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

    /* Ensure no horizontal scroll for content sections */
    .page-gdpr__content-section,
    .page-gdpr__container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        overflow-x: hidden;
    }

    /* Buttons mobile adaptation (if any, though none explicitly here) */
    .page-gdpr__cta-button,
    .page-gdpr__btn-primary,
    .page-gdpr__btn-secondary,
    .page-gdpr a[class*="button"],
    .page-gdpr 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-gdpr__cta-buttons,
    .page-gdpr__button-group,
    .page-gdpr__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;
      overflow-x: hidden;
    }
}