/* style/download.css */

/* CSS Variables */
:root {
  --primary-color: #FFD700; /* Gold */
  --secondary-color: #1E90FF; /* Royal Blue */
  --text-dark: #333333;
  --text-light: #ffffff;
  --background-light: #f9f9f9;
  --background-dark: #2a2a2a; /* Slightly darker than royal blue for contrast */
  --border-color: #e0e0e0;
}

/* Base styles for the page-download scope */
.page-download {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-dark); /* Default text color for light background */
  background-color: #ffffff; /* Default body background is white */
}

.page-download__section {
  padding: 60px 20px;
  text-align: center;
}

.page-download__section--light-bg {
  background-color: var(--background-light);
  color: var(--text-dark);
}

.page-download__section--dark-bg {
  background-color: var(--background-dark);
  color: var(--text-light);
}

.page-download__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px; /* Add padding for inner content */
}

.page-download__section-title {
  font-size: 36px;
  margin-bottom: 20px;
  color: var(--primary-color);
  font-weight: bold;
}

.page-download__section-title--light {
  color: var(--text-light);
}

.page-download__section-subtitle {
  font-size: 18px;
  margin-bottom: 40px;
  color: #666666;
}

.page-download__section-subtitle--light {
  color: #cccccc;
}

/* Hero Section */
.page-download__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 spacing */
  background: linear-gradient(135deg, var(--secondary-color), #00008B); /* Darker blue for hero background */
  color: var(--text-light);
  overflow: hidden;
}

.page-download__hero-container {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: row; /* Desktop: row layout */
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  z-index: 1;
}

.page-download__hero-content {
  flex: 1;
  text-align: left;
}

.page-download__hero-title {
  font-size: 48px;
  margin-bottom: 20px;
  color: var(--primary-color); /* Gold title */
  line-height: 1.2;
}

.page-download__hero-description {
  font-size: 20px;
  margin-bottom: 30px;
  color: var(--text-light);
}

.page-download__hero-buttons {
  display: flex;
  gap: 20px;
  justify-content: flex-start;
}

.page-download__hero-image-wrapper {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

.page-download__hero-image {
  width: 100%;
  height: auto;
  max-width: 600px; /* Constrain image size */
  display: block;
  border-radius: 12px;
  object-fit: contain;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.page-download__cta-button {
  display: inline-block;
  padding: 15px 40px;
  text-decoration: none;
  border-radius: 8px;
  font-size: 18px;
  font-weight: bold;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  max-width: 100%; /* Ensure responsiveness */
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.page-download__cta-button--primary {
  background: var(--primary-color);
  color: var(--text-dark);
  border: 2px solid var(--primary-color);
}

.page-download__cta-button--primary:hover {
  background: #e6c200; /* Slightly darker gold */
  border-color: #e6c200;
  transform: translateY(-2px);
}

.page-download__cta-button--secondary {
  background: var(--secondary-color);
  color: var(--text-light);
  border: 2px solid var(--secondary-color);
}

.page-download__cta-button--secondary:hover {
  background: #1a7ad9; /* Slightly darker blue */
  border-color: #1a7ad9;
  transform: translateY(-2px);
}

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

.page-download__feature-card {
  background-color: #ffffff;
  border-radius: 12px;
  padding: 30px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%; /* Ensure cards are same height */
  display: flex;
  flex-direction: column;
  align-items: center;
}

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

.page-download__feature-icon {
  width: 100%;
  max-width: 150px;
  height: auto;
  margin-bottom: 20px;
  object-fit: contain;
  border-radius: 8px;
}

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

.page-download__feature-description {
  font-size: 16px;
  color: #555555;
  flex-grow: 1;
}

/* How to Download Section */
.page-download__how-to-download-section {
  padding: 80px 20px;
}

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

.page-download__step-item {
  text-align: center;
  position: relative;
  padding: 20px;
  background-color: rgba(255, 255, 255, 0.08); /* Semi-transparent white on dark background */
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

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

.page-download__step-title {
  font-size: 28px;
  color: var(--text-light);
  margin-bottom: 15px;
  font-weight: bold;
}

.page-download__step-description {
  font-size: 16px;
  color: #e0e0e0;
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-download__step-image-wrapper, .page-download__qr-code-wrapper {
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
}

.page-download__step-image, .page-download__qr-code {
  width: 100%;
  height: auto;
  border-radius: 8px;
  object-fit: contain;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

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

/* System Requirements Section */
.page-download__system-requirements-section {
  padding: 80px 20px;
}

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

.page-download__requirement-card {
  background-color: #ffffff;
  border-radius: 12px;
  padding: 30px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
  text-align: left;
  display: flex;
  flex-direction: column;
  height: 100%;
}

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

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

.page-download__requirement-card ul li {
  font-size: 16px;
  color: #555555;
  margin-bottom: 10px;
  position: relative;
  padding-left: 25px;
}

.page-download__requirement-card ul li::before {
  content: '✓';
  color: var(--primary-color);
  position: absolute;
  left: 0;
  font-weight: bold;
}

.page-download__requirement-image {
  width: 100%;
  height: auto;
  max-width: 400px;
  display: block;
  margin-top: auto; /* Push image to bottom */
  border-radius: 8px;
  object-fit: contain;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* FAQ Section */
.page-download__faq-section {
  padding: 80px 20px;
}

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

.page-download__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
  background-color: var(--background-dark);
}

.page-download__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: #3a3a3a; /* Slightly lighter dark background for question */
  border: 1px solid #4a4a4a;
  border-radius: 5px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
}

.page-download__faq-question:hover {
  background: #4a4a4a;
  border-color: #5a5a5a;
}

.page-download__faq-question:active {
  background: #5a5a5a;
}

.page-download__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--text-light);
  pointer-events: none;
}

.page-download__faq-toggle {
  font-size: 28px;
  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;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
}

.page-download__faq-item.active .page-download__faq-toggle {
  color: var(--text-light);
  transform: rotate(45deg); /* Rotate for minus sign effect */
}

.page-download__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 20px;
  opacity: 0;
  background: #333333; /* Darker background for answer */
  border-top: 1px solid #4a4a4a;
  border-radius: 0 0 5px 5px;
}

.page-download__faq-item.active .page-download__faq-answer {
  max-height: 2000px !important;
  padding: 20px !important;
  opacity: 1;
}

.page-download__faq-answer p {
  color: #cccccc;
  font-size: 16px;
  margin-bottom: 10px;
}

.page-download__faq-support-link {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: bold;
}

.page-download__faq-support-link:hover {
  text-decoration: underline;
}

/* CTA Section */
.page-download__cta-section {
  padding: 80px 20px;
}

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

/* Responsive Design */
@media (max-width: 1024px) {
  .page-download__hero-title {
    font-size: 40px;
  }
  .page-download__hero-description {
    font-size: 18px;
  }
  .page-download__hero-container {
    flex-direction: column;
  }
  .page-download__hero-content {
    text-align: center;
    margin-bottom: 40px;
  }
  .page-download__hero-buttons {
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .page-download__hero-section {
    padding-top: var(--header-offset, 120px) !important;
    padding-bottom: 40px;
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-download__hero-title {
    font-size: 32px;
  }
  .page-download__hero-description {
    font-size: 16px;
  }
  .page-download__hero-buttons {
    flex-direction: column;
    gap: 15px;
  }
  .page-download__cta-button {
    width: 100% !important;
    max-width: 100% !important;
    padding: 12px 25px;
    font-size: 16px;
  }
  .page-download__section-title {
    font-size: 28px;
  }
  .page-download__section-subtitle {
    font-size: 16px;
  }
  .page-download__features-grid,
  .page-download__download-steps,
  .page-download__requirements-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .page-download__feature-card,
  .page-download__step-item,
  .page-download__requirement-card {
    padding: 20px;
  }
  .page-download__feature-title {
    font-size: 20px;
  }
  .page-download__step-title {
    font-size: 22px;
  }
  .page-download__faq-question h3 {
    font-size: 16px;
  }
  .page-download__faq-toggle {
    font-size: 24px;
    width: 28px;
    height: 28px;
  }
  .page-download__faq-answer {
    padding: 0 15px;
  }
  .page-download__faq-item.active .page-download__faq-answer {
    padding: 15px !important;
  }
  .page-download__download-buttons, .page-download__cta-buttons {
    flex-direction: column;
    gap: 15px;
  }
  
  /* Mobile image responsiveness */
  .page-download img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  
  .page-download__section,
  .page-download__container,
  .page-download__hero-content,
  .page-download__hero-buttons,
  .page-download__download-buttons,
  .page-download__cta-buttons {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
  /* Ensure button containers allow wrapping if multiple buttons are present */
  .page-download__hero-buttons, .page-download__download-buttons, .page-download__cta-buttons {
    flex-wrap: wrap !important;
  }
}

@media (max-width: 480px) {
  .page-download__hero-title {
    font-size: 28px;
  }
  .page-download__section-title {
    font-size: 24px;
  }
  .page-download__cta-button {
    font-size: 15px;
    padding: 10px 20px;
  }
}