/*
* PLAN CODE - Legal Pages Stylesheet
* Version: 1.0
*/

:root {
  --primary-color: #6f42c1;
  --primary-dark: #5a32a3;
  --primary-light: #8c68d6;
  --secondary-color: #20c997;
  --dark-color: #111;
  --light-color: #f8f9fa;
  --gray-color: #6c757d;
  --bg-dark: #121212;
  --bg-light: #ffffff;
  --text-dark: #212529;
  --text-light: #f8f9fa;
  --border-color: rgba(255, 255, 255, 0.1);
  --shadow-color: rgba(0, 0, 0, 0.1);
  --transition: all 0.3s ease;
  --font-family: "Cairo", sans-serif;
}

body {
  min-height: 100vh;
  font-family: var(--font-family);
  background-color: var(--bg-light);
  color: var(--text-dark);
  transition: var(--transition);
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

body.dark-mode {
  background-color: var(--bg-dark);
  color: var(--text-light);
}

.legal-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 2rem 0;
  overflow: hidden;
}

/* Language Switcher */
.language-switcher {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1000;
  display: flex;
  background-color: rgba(0, 0, 0, 0.2);
  border-radius: 30px;
  padding: 5px;
  backdrop-filter: blur(10px);
}

.lang-btn {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.7);
  padding: 5px 15px;
  border-radius: 20px;
  cursor: pointer;
  font-size: 0.875rem;
  transition: var(--transition);
}

.lang-btn.active {
  background-color: var(--primary-color);
  color: white;
}

/* Theme Switcher */
.theme-switcher {
  position: fixed;
  top: 20px;
  left: 20px;
  z-index: 1000;
}

.theme-switcher button {
  background-color: rgba(0, 0, 0, 0.2);
  border: none;
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  backdrop-filter: blur(10px);
}

.theme-switcher button:hover {
  background-color: rgba(0, 0, 0, 0.4);
}

body:not(.dark-mode) #dark-icon {
  display: none;
}

body.dark-mode #light-icon {
  display: none;
}

/* Legal Container */
.legal-container {
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  z-index: 10;
}

/* Logo */
.legal-logo {
  text-align: center;
  margin-bottom: 2rem;
}

.logo-img {
  height: 60px;
  transition: var(--transition);
}

.light-logo {
  display: block;
  margin: 0 auto;
}

.dark-logo {
  display: none;
  margin: 0 auto;
}

body.dark-mode .light-logo {
  display: none;
}

body.dark-mode .dark-logo {
  display: block;
}

/* Legal Card */
.legal-card {
  background-color: var(--bg-light);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  transition: var(--transition);
  padding: 2rem;
}

.dark-mode .legal-card {
  background-color: rgba(255, 255, 255, 0.05);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* Legal Header */
.legal-header {
  text-align: center;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.dark-mode .legal-header {
  border-bottom-color: rgba(255, 255, 255, 0.1);
}

.legal-title {
  font-size: 2rem;
  margin-bottom: 0.5rem;
  color: var(--primary-color);
  font-weight: 700;
}

.dark-mode .legal-title {
  color: var(--primary-light);
}

.legal-subtitle {
  color: var(--gray-color);
  margin-bottom: 0;
}

.dark-mode .legal-subtitle {
  color: rgba(255, 255, 255, 0.7);
}

/* Legal Content */
.legal-content {
  line-height: 1.8;
}

.legal-section {
  margin-bottom: 2.5rem;
}

.legal-section h2 {
  color: var(--primary-color);
  margin-bottom: 1rem;
  font-weight: 600;
  font-size: 1.5rem;
}

.dark-mode .legal-section h2 {
  color: var(--primary-light);
}

.legal-section h3 {
  color: var(--text-dark);
  margin-bottom: 0.75rem;
  font-weight: 600;
  font-size: 1.25rem;
}

.dark-mode .legal-section h3 {
  color: var(--text-light);
}

.legal-section p {
  margin-bottom: 1rem;
}

.legal-section ul {
  padding-right: 1.5rem;
  margin-bottom: 1.5rem;
}

.legal-section ul li {
  margin-bottom: 0.5rem;
}

/* Legal Footer */
.legal-footer {
  text-align: center;
  margin-top: 2rem;
  color: var(--gray-color);
}

.dark-mode .legal-footer {
  color: rgba(255, 255, 255, 0.7);
}

.legal-links {
  margin-top: 1rem;
}

.legal-links a {
  color: var(--primary-color);
  text-decoration: none;
  margin: 0 10px;
  transition: var(--transition);
}

.dark-mode .legal-links a {
  color: var(--primary-light);
}

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

/* Decorative Elements */
.legal-page::before {
  content: "";
  position: absolute;
  top: -100px;
  right: -100px;
  width: 300px;
  height: 300px;
  background-color: rgba(111, 66, 193, 0.1);
  border-radius: 50%;
  filter: blur(60px);
  z-index: 0;
}

.legal-page::after {
  content: "";
  position: absolute;
  bottom: -200px;
  left: -200px;
  width: 400px;
  height: 400px;
  background-color: rgba(32, 201, 151, 0.1);
  border-radius: 50%;
  filter: blur(60px);
  z-index: 0;
}

/* Responsive Styles */
@media (max-width: 767.98px) {
  .legal-container {
    max-width: 100%;
    padding: 0 1rem;
  }

  .legal-card {
    padding: 1.5rem;
    border-radius: 15px;
  }

  .legal-title {
    font-size: 1.75rem;
  }

  .legal-section h2 {
    font-size: 1.35rem;
  }

  .legal-section h3 {
    font-size: 1.15rem;
  }

  .language-switcher,
  .theme-switcher {
    top: 10px;
  }

  .language-switcher {
    right: 10px;
  }

  .theme-switcher {
    left: 10px;
  }
}

/* RTL and LTR Support */
html[dir="ltr"] .language-switcher {
  right: auto;
  left: 20px;
}

html[dir="ltr"] .theme-switcher {
  left: auto;
  right: 20px;
}

html[dir="ltr"] .legal-section ul {
  padding-right: 0;
  padding-left: 1.5rem;
}

@media (max-width: 767.98px) {
  html[dir="ltr"] .language-switcher {
    left: 10px;
  }

  html[dir="ltr"] .theme-switcher {
    right: 10px;
  }
}

/* Dark Mode Background */
body.dark-mode .legal-page {
  background-color: var(--bg-dark);
}

/* Animation for theme change */
.theme-transition {
  transition: background-color 0.5s ease, color 0.5s ease;
}
