/* ==========================================================================
   Pages Styles - Contact, Legal, etc.
   ========================================================================== */

/* --------------------------------------------------------------------------
   Page Hero
   -------------------------------------------------------------------------- */
.page-hero {
  padding: 10rem 0 4rem;
  text-align: center;
}

.page-hero--legal {
  padding-bottom: 2rem;
}

.page-hero .section-header {
  max-width: 720px;
  margin: 0 auto;
}

.page-hero .section-title {
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  margin-bottom: 1rem;
}

.page-hero .section-description {
  font-size: 1.125rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 600px;
  margin: 0 auto;
}

.legal-updated {
  display: inline-block;
  margin-top: 1.5rem;
  padding: 0.5rem 1rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 999px;
  font-size: 0.875rem;
  color: var(--text-tertiary);
}

/* --------------------------------------------------------------------------
   Contact Page
   -------------------------------------------------------------------------- */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  max-width: 800px;
  margin: 3rem auto 0;
}

@media (max-width: 640px) {
  .contact-grid {
    grid-template-columns: 1fr;
  }
}

.contact-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 2.5rem 2rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: inherit;
  transition:
    transform 0.4s var(--ease-out-expo),
    background 0.4s var(--ease-out-expo);
  overflow: hidden;
}

.contact-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    transparent 0%,
    rgba(99, 102, 241, 0.05) 100%
  );
  opacity: 0;
  transition: opacity 0.3s ease;
}

.contact-card::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  border: 2.5px solid var(--primary);
  box-shadow: 0 8px 32px -8px var(--primary-glow);
  opacity: 0;
  transition: opacity 0.4s var(--ease-out-expo);
  pointer-events: none;
}

.contact-card:hover {
  background: var(--bg-card-hover);
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.contact-card:hover::before {
  opacity: 1;
}

.contact-card:hover::after {
  opacity: 1;
}

.contact-card-icon {
  position: relative;
  z-index: 1;
  width: 64px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 1rem;
  margin-bottom: 1.5rem;
  transition: transform 0.3s ease;
}

.contact-card:hover .contact-card-icon {
  transform: scale(1.1);
}

.contact-card-icon.discord {
  background: linear-gradient(135deg, #5865f2 0%, #7289da 100%);
  color: white;
}

.contact-card-icon.email {
  background: linear-gradient(
    135deg,
    var(--primary) 0%,
    var(--primary-light) 100%
  );
  color: white;
}

.contact-card-content {
  position: relative;
  z-index: 1;
}

.contact-card-content h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}

.contact-card-content p {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
}

/* Contact Hint */
.contact-hint {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  margin: 2.5rem auto 0;
  padding: 0.75rem 1.25rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 999px;
  font-size: 0.875rem;
  color: var(--text-secondary);
  word-spacing: 0.05em;
}

.contact-hint svg {
  flex-shrink: 0;
  color: #5865f2;
}

.contact-hint-wrapper {
  text-align: center;
}

/* --------------------------------------------------------------------------
   Legal Pages (Privacy Policy, Terms)
   -------------------------------------------------------------------------- */
.legal-section {
  padding: 2rem 0 6rem;
}

.legal-wrapper {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 4rem;
  max-width: 1100px;
  margin: 0 auto;
}

@media (max-width: 1024px) {
  .legal-wrapper {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

/* Table of Contents */
.legal-toc {
  position: sticky;
  top: 100px;
  align-self: start;
  padding: 1.5rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 1rem;
  max-height: calc(100vh - 140px);
  overflow-y: auto;
}

@media (max-width: 1024px) {
  .legal-toc {
    position: static;
    max-height: none;
  }
}

.legal-toc h4 {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-tertiary);
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-color);
}

.legal-toc nav {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.legal-toc a {
  display: block;
  padding: 0.5rem 0.75rem;
  font-size: 0.8125rem;
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: 0.5rem;
  transition: all 0.2s ease;
  line-height: 1.4;
}

.legal-toc a:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

/* Legal Content */
.legal-content {
  min-width: 0;
}

.legal-intro {
  padding: 2rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 1rem;
  margin-bottom: 3rem;
}

.legal-intro p {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 1rem;
}

.legal-intro p:last-child {
  margin-bottom: 0;
}

.legal-content section {
  margin-bottom: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--border-color);
}

.legal-content section:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.legal-content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--primary);
  display: inline-block;
}

.legal-content h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 2rem 0 1rem;
}

.legal-content p {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 1rem;
}

.legal-content ul {
  margin: 1rem 0 1.5rem;
  padding-left: 0;
  list-style: none;
}

.legal-content li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.75rem;
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

.legal-content li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 6px;
  height: 6px;
  background: var(--primary);
  border-radius: 50%;
}

.legal-content li strong {
  color: var(--text-primary);
}

.legal-content a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

.legal-content a:hover {
  color: var(--primary-light);
  text-decoration: underline;
}

/* Legal Notice Box */
.legal-notice {
  padding: 1.25rem 1.5rem;
  background: rgba(251, 191, 36, 0.1);
  border: 1px solid rgba(251, 191, 36, 0.3);
  border-radius: 0.75rem;
  margin: 1.5rem 0;
}

.legal-notice strong {
  color: #fbbf24;
}

/* Legal Contact Box */
.legal-contact {
  padding: 1.5rem;
  background: rgba(99, 102, 241, 0.05);
  border: 1px solid rgba(99, 102, 241, 0.2);
  border-radius: 0.75rem;
  margin: 1rem 0;
}

.legal-contact p {
  margin-bottom: 0.5rem;
  font-size: 1rem;
}

.legal-contact p:last-child {
  margin-bottom: 0;
}

/* Legal Info Block */
.legal-info-block {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  padding: 1.5rem;
  margin: 1rem 0 1.5rem;
}

.legal-info-block p {
  margin: 0.25rem 0;
  font-size: 0.9375rem;
}

.legal-info-block p:first-child {
  font-size: 1.125rem;
  margin-bottom: 0.5rem;
}

/* --------------------------------------------------------------------------
   Scrollbar Styling for TOC
   -------------------------------------------------------------------------- */
.legal-toc::-webkit-scrollbar {
  width: 4px;
}

.legal-toc::-webkit-scrollbar-track {
  background: transparent;
}

.legal-toc::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 4px;
}

.legal-toc::-webkit-scrollbar-thumb:hover {
  background: var(--text-tertiary);
}

/* --------------------------------------------------------------------------
   Animations
   -------------------------------------------------------------------------- */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

[data-animate="fade-up"] {
  opacity: 0;
  animation: fadeUp 0.6s ease forwards;
}

[data-delay="200"] {
  animation-delay: 0.2s;
}

[data-delay="300"] {
  animation-delay: 0.3s;
}
