/* FAQ Page Styles - Matching Nexus Investment FX Design */

/* Background Image Section (Matching contact.html) */
.background-image-section {
  position: relative;
  height: 290px;
  overflow: hidden;
  padding: 50px 60px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
}

.background-image-section .bg-image-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
}

.background-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.background-image-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    rgba(5, 48, 92, 0.7) 0%,
    rgba(10, 74, 138, 0.8) 100%
  );
  z-index: 0;
}

.header-text {
  position: relative;
  z-index: 1;
  margin-bottom: 40px;
  animation: slideInLeft 0.6s ease-out;
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.header-text h1 {
  font-size: 50px;
  color: #ffffff;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 1px;
  text-transform: capitalize;
  margin-bottom: 0;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.header-text h1::after {
  content: "";
  display: block;
  width: 60%;
  height: 4px;
  background: linear-gradient(90deg, #ef9227 0%, #fabc2e 100%);
  margin-top: 5px;
  border-radius: 2px;
}

.header-text-links {
  position: relative;
  z-index: 1;
  font-size: 18px;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 400;
}

/* FAQ Search Section */
.faq-search-section {
  background: #ffffff;
  padding: 60px 20px;
  margin: 0;
}

.faq-search-container {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
}

.faq-search-container h2 {
  font-size: 48px;
  font-weight: 700;
  color: #05305c;
  margin-bottom: 30px;
}

.search-box {
  position: relative;
  max-width: 600px;
  margin: 0 auto;
}

.search-icon {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  width: 24px;
  height: 24px;
  fill: #999;
  pointer-events: none;
}

.search-box input {
  width: 100%;
  padding: 18px 20px 18px 60px;
  font-size: 16px;
  border: 2px solid #e0e0e0;
  border-radius: 50px;
  outline: none;
  transition: all 0.3s ease;
  font-family: inherit;
}

.search-box input:focus {
  border-color: #0a4a8a;
  box-shadow: 0 0 0 4px rgba(10, 74, 138, 0.1);
}

.search-box input::placeholder {
  color: #999;
}

/* FAQ Categories Navigation */
.faq-categories-nav {
  background: #f8f9fa;
  padding: 30px 20px;
  border-bottom: 1px solid #e0e0e0;
  position: sticky;
  z-index: 50;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.categories-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
  justify-content: center;
}

.category-btn {
  padding: 12px 24px;
  background: #ffffff;
  border: 2px solid #e0e0e0;
  border-radius: 25px;
  font-size: 15px;
  font-weight: 600;
  color: #666;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
  font-family: inherit;
}

.category-btn:hover {
  background: #05305c;
  color: #ffffff;
  border-color: #05305c;
  box-shadow: 0 4px 12px rgba(5, 48, 92, 0.2);
}

.category-btn.active {
  background: linear-gradient(135deg, #05305c 0%, #0a4a8a 100%);
  color: #ffffff;
  border-color: #05305c;
  box-shadow: 0 4px 12px rgba(5, 48, 92, 0.3);
}

/* FAQ Content Section */
.faq-content-section {
  background: #ffffff;
  padding: 60px 20px 80px;
}

.faq-content-container {
  max-width: 1000px;
  margin: 0 auto;
}

/* FAQ Category */
.faq-category {
  margin-bottom: 60px;
  animation: fadeInUp 0.6s ease-out;
}

.faq-category.hidden {
  display: none;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.category-title {
  font-size: 30px;
  font-weight: 700;
  color: #05305c;
  margin-bottom: 30px;
  padding-bottom: 15px;
  border-bottom: 3px solid #0a4a8a;
  display: flex;
  align-items: center;
  gap: 12px;
}

.category-title svg {
  width: 32px;
  height: 32px;
  fill: #0a4a8a;
}

/* FAQ Item */
.faq-item {
  background: #ffffff;
  border: 2px solid #e8ecf0;
  border-radius: 12px;
  margin-bottom: 16px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-item:hover {
  border-color: #0a4a8a;
  box-shadow: 0 4px 15px rgba(10, 74, 138, 0.1);
}

.faq-item.active {
  border-color: #0a4a8a;
  box-shadow: 0 6px 20px rgba(10, 74, 138, 0.15);
}

/* FAQ Question Button */
.faq-question {
  width: 100%;
  padding: 20px 60px 20px 25px;
  background: transparent;
  border: none;
  text-align: left;
  font-size: 20px;
  font-weight: 600;
  color: #05305c;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  transition: all 0.3s ease;
  font-family: inherit;
}

.faq-question:hover {
  color: #0a4a8a;
  background: #f8f9fa;
}

.faq-item.active .faq-question {
  background: linear-gradient(135deg, #05305c 0%, #0a4a8a 100%);
  color: #ffffff;
}

.faq-question span {
  flex: 1;
  padding-right: 20px;
}

.faq-icon {
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  fill: currentColor;
  transition: transform 0.3s ease;
}

.faq-item.active .faq-icon {
  transform: translateY(-50%) rotate(180deg);
}

/* FAQ Answer */
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
  background: #f8f9fa;
}

.faq-item.active .faq-answer {
  max-height: 2000px;
  padding: 25px;
  border-top: 2px solid rgba(10, 74, 138, 0.1);
}

.faq-answer p {
  color: #444;
  font-size: 17px;
  line-height: 1.8;
  margin-bottom: 15px;
}

.faq-answer p:last-child {
  margin-bottom: 0;
}

.faq-answer ul,
.faq-answer ol {
  margin: 15px 0;
  padding-left: 25px;
}

.faq-answer li {
  color: #444;
  font-size: 16px;
  line-height: 1.8;
  margin-bottom: 10px;
}

.faq-answer li::marker {
  color: #0a4a8a;
  font-weight: bold;
}

.faq-answer strong {
  color: #05305c;
  font-weight: 600;
}

.faq-answer a {
  color: #0a4a8a;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease;
}

.faq-answer a:hover {
  color: #05305c;
  text-decoration: underline;
}

/* Contact Section */
.faq-contact-section {
  max-width: 800px;
  margin: 60px auto 0;
  padding: 0 20px;
}

.faq-contact-card {
  background: linear-gradient(135deg, #05305c 0%, #0a4a8a 100%);
  color: #ffffff;
  padding: 50px;
  border-radius: 16px;
  text-align: center;
  box-shadow: 0 10px 30px rgba(5, 48, 92, 0.3);
}

.contact-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  margin-bottom: 25px;
}

.contact-icon svg {
  width: 40px;
  height: 40px;
  fill: #ffffff;
}

.faq-contact-card h3 {
  font-size: 32px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 15px;
}

.faq-contact-card p {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 30px;
  line-height: 1.6;
}

.contact-buttons {
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn-primary,
.btn-secondary {
  padding: 14px 32px;
  font-size: 17px;
  font-weight: 600;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.3s ease;
  display: inline-block;
  font-family: inherit;
}

.btn-primary {
  background: #ffffff;
  color: #05305c;
  border: 2px solid #ffffff;
}

.btn-primary:hover {
  background: transparent;
  color: #ffffff;
  box-shadow: 0 6px 20px rgba(255, 255, 255, 0.3);
}

.btn-secondary {
  background: transparent;
  color: #ffffff;
  border: 2px solid #ffffff;
}

.btn-secondary:hover {
  background: #ffffff;
  color: #05305c;
  box-shadow: 0 6px 20px rgba(255, 255, 255, 0.3);
}

/* No Results Message */
.no-results {
  text-align: center;
  padding: 60px 20px;
  color: #666;
  display: none;
}

.no-results.show {
  display: block;
}

.no-results svg {
  width: 80px;
  height: 80px;
  fill: #ccc;
  margin-bottom: 20px;
}

.no-results h3 {
  font-size: 24px;
  color: #333;
  margin-bottom: 10px;
}

.no-results p {
  font-size: 16px;
  color: #666;
}

/* Highlighted Search Term */
.highlight {
  background: #fef3c7;
  padding: 2px 4px;
  border-radius: 3px;
  font-weight: 600;
}

/* Responsive Design */
@media (max-width: 768px) {
  .background-image-section {
    height: 220px;
    padding: 30px 25px;
  }

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

  .page-subtitle {
    font-size: 16px;
  }

  .faq-search-section {
    padding: 40px 20px;
  }

  .faq-search-container h2 {
    font-size: 24px;
    margin-bottom: 20px;
  }

  .search-box input {
    padding: 15px 15px 15px 50px;
    font-size: 15px;
  }

  .search-icon {
    left: 15px;
    width: 20px;
    height: 20px;
  }

  .faq-categories-nav {
    padding: 20px 15px;
  }

  .categories-container {
    gap: 10px;
  }

  .category-btn {
    padding: 10px 18px;
    font-size: 13px;
  }

  .faq-content-section {
    padding: 40px 15px 60px;
  }

  .faq-category {
    margin-bottom: 40px;
  }

  .category-title {
    font-size: 22px;
    margin-bottom: 20px;
    gap: 10px;
  }

  .category-title svg {
    width: 26px;
    height: 26px;
  }

  .faq-question {
    padding: 18px 50px 18px 20px;
    font-size: 16px;
  }

  .faq-icon {
    right: 15px;
    width: 24px;
    height: 24px;
  }

  .faq-item.active .faq-answer {
    padding: 20px;
  }

  .faq-answer p,
  .faq-answer li {
    font-size: 15px;
  }

  .faq-contact-card {
    padding: 35px 25px;
  }

  .faq-contact-card h3 {
    font-size: 24px;
  }

  .faq-contact-card p {
    font-size: 15px;
  }

  .contact-buttons {
    flex-direction: column;
    gap: 12px;
  }

  .btn-primary,
  .btn-secondary {
    width: 100%;
    padding: 12px 24px;
    font-size: 15px;
  }
}

@media (max-width: 480px) {
  .background-image-section {
    height: 200px;
    padding: 25px 20px;
  }

  .header-text h1 {
    font-size: 32px;
    letter-spacing: 0.5px;
  }

  .header-text h1::after {
    width: 50%;
    height: 3px;
    margin-top: 8px;
  }

  .header-text-links {
    font-size: 17px;
    margin-bottom: 10px;
  }

  .faq-search-section {
    padding: 30px 15px;
  }

  .faq-search-container h2 {
    font-size: 32px;
  }

  .search-box input {
    padding: 14px 14px 14px 45px;
    font-size: 16px;
  }

  .category-btn {
    padding: 8px 16px;
    font-size: 14px;
  }

  .category-title {
    font-size: 25px;
  }

  .faq-question {
    padding: 15px 45px 15px 18px;
    font-size: 18px;
  }

  .faq-answer p,
  .faq-answer li {
    font-size: 16px;
  }

  .contact-icon {
    width: 60px;
    height: 60px;
  }

  .contact-icon svg {
    width: 30px;
    height: 30px;
  }

  .faq-contact-card h3 {
    font-size: 24px;
  }

  .faq-contact-card p {
    font-size: 16px;
  }

  .btn-primary,
  .btn-secondary {
    font-size: 15px;
  }
}

/* Print Styles */
@media print {
  .background-image-section,
  .faq-search-section,
  .faq-categories-nav,
  .faq-contact-section,
  header,
  footer {
    display: none;
  }

  .faq-item {
    page-break-inside: avoid;
    border: 1px solid #000;
  }

  .faq-answer {
    max-height: none;
    display: block;
    padding: 20px;
  }

  .faq-item.active .faq-question {
    background: #f0f0f0;
    color: #000;
  }
}

/* Accessibility */
.faq-question:focus {
  outline: 2px solid #0a4a8a;
  outline-offset: 2px;
}

.category-btn:focus {
  outline: 2px solid #0a4a8a;
  outline-offset: 2px;
}

/* Loading Animation */
@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

.loading {
  animation: pulse 1.5s ease-in-out infinite;
}
