@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800&display=swap');

:root {
  /* Design Tokens - Colors */
  --bg-color: hsl(225, 30%, 4%);
  --bg-gradient-start: hsl(225, 30%, 3%);
  --bg-gradient-end: hsl(225, 25%, 7%);
  
  --text-primary: hsl(0, 0%, 100%);
  --text-secondary: hsl(220, 15%, 75%);
  --text-muted: hsl(220, 10%, 55%);
  
  --accent-cyan: hsl(183, 100%, 50%); /* #00f2fe */
  --accent-blue: hsl(208, 99%, 60%); /* #4facfe */
  --accent-purple: oklch(65% 0.25 310);
  
  --card-bg: rgba(255, 255, 255, 0.02);
  --card-bg-hover: rgba(255, 255, 255, 0.05);
  --card-border: rgba(255, 255, 255, 0.07);
  --card-border-hover: rgba(255, 255, 255, 0.15);
  
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.5);
  --shadow-md: 0 8px 30px rgba(0, 0, 0, 0.6);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.7);

  /* Fonts */
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;
  
  /* Scrollbars - modern-web-guidance recommended */
  --color-scrollbar-track: rgba(255, 255, 255, 0.02);
  --color-scrollbar-thumb: rgba(255, 255, 255, 0.12);
  --color-scrollbar-thumb-hover: rgba(255, 255, 255, 0.25);
  
  scrollbar-color: var(--color-scrollbar-thumb) var(--color-scrollbar-track);
}

/* Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  color-scheme: dark;
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-color);
  background-image: radial-gradient(circle at 10% 20%, rgba(112, 0, 255, 0.08) 0%, transparent 40%),
                    radial-gradient(circle at 90% 80%, rgba(0, 242, 254, 0.06) 0%, transparent 40%),
                    linear-gradient(to bottom, var(--bg-gradient-start), var(--bg-gradient-end));
  background-attachment: fixed;
  color: var(--text-secondary);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow-x: hidden;
}

/* Typography spacing & utility */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--text-primary);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

h1 {
  font-size: clamp(2.2rem, 1.2rem + 4vw, 3.8rem);
  margin-bottom: 0.5rem;
}

h2 {
  font-size: clamp(1.5rem, 1rem + 2vw, 2.2rem);
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

h3 {
  font-size: 1.3rem;
  margin-top: 2rem;
  margin-bottom: 0.8rem;
}

p {
  margin-bottom: 1.2rem;
  font-size: clamp(0.95rem, 0.9rem + 0.2vw, 1.05rem);
}

a {
  color: var(--text-primary);
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Focus indicator styling - modern accessibility */
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--accent-cyan);
  outline-offset: 4px;
}

/* Layout container */
.container {
  max-width: 900px;
  width: 100%;
  margin: 0 auto;
  padding: 2.5rem 1.5rem;
}

/* Homepage specific large container */
.homepage-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex-grow: 1;
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
}

/* Brand header */
.brand-header {
  margin-bottom: 3.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.brand-logo {
  width: 90px;
  height: 90px;
  margin-bottom: 1.5rem;
  filter: drop-shadow(0 0 15px rgba(0, 242, 254, 0.3));
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  border-radius: 50%;
  object-fit: cover;
}

.brand-logo:hover {
  transform: rotate(15deg) scale(1.05);
}

.brand-name {
  font-size: clamp(2rem, 1.5rem + 2vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, var(--text-primary) 30%, var(--text-secondary) 70%, var(--accent-blue) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-subtitle {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-cyan);
  font-weight: 600;
  margin-top: 0.25rem;
}

/* Glassmorphism Link Patches/Cards */
.links-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
  width: 100%;
  margin-bottom: 2rem;
}

@media (min-width: 480px) {
  .links-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.glass-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 2rem 1.5rem;
  backdrop-filter: blur(16px) saturate(120%);
  -webkit-backdrop-filter: blur(16px) saturate(120%);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Decorative backdrop glow for cards */
.glass-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(800px circle at var(--x, 0px) var(--y, 0px), rgba(0, 242, 254, 0.08), transparent 40%);
  z-index: 1;
  opacity: 0;
  transition: opacity 0.5s ease;
}

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

.glass-card:hover {
  background: var(--card-bg-hover);
  border-color: var(--card-border-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.glass-card:active {
  transform: translateY(-1px);
}

.glass-card-icon {
  margin-bottom: 1rem;
  color: var(--accent-cyan);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 2;
}

.glass-card:hover .glass-card-icon {
  transform: scale(1.1) translateY(-2px);
}

.glass-card-title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  z-index: 2;
}

.glass-card-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  z-index: 2;
}

/* Legal Documents Styling */
.legal-header {
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding-bottom: 1.5rem;
  margin-bottom: 2.5rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.legal-header .brand-logo {
  width: 48px;
  height: 48px;
  margin-bottom: 0;
  border-radius: 50%;
  object-fit: cover;
}

.legal-header-text {
  display: flex;
  flex-direction: column;
}

.legal-header-title {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
}

.legal-header-brand {
  font-size: 0.85rem;
  color: var(--accent-cyan);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.effective-date {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  font-style: italic;
}

.legal-content {
  background: rgba(255, 255, 255, 0.015);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 16px;
  padding: 2.5rem 2rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: var(--shadow-sm);
  margin-bottom: 3rem;
}

.legal-content p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.legal-content ul, .legal-content ol {
  margin-left: 1.5rem;
  margin-bottom: 1.5rem;
  color: var(--text-secondary);
}

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

/* Navigation between legal files at the bottom */
.legal-navigation {
  display: flex;
  justify-content: center;
  margin-bottom: 2rem;
}

.legal-nav-link {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  padding: 0.8rem 1.5rem;
  border-radius: 30px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--accent-cyan);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
  min-height: 48px; /* accessibility touch target */
}

.legal-nav-link:hover {
  background: var(--card-bg-hover);
  border-color: var(--accent-cyan);
  color: var(--text-primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.legal-nav-link svg {
  transition: transform 0.3s ease;
}

.legal-nav-link:hover svg {
  transform: translateX(3px);
}

/* Footer style */
footer {
  text-align: center;
  padding: 2.5rem 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  background-color: rgba(225, 230, 240, 0.005);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-brand {
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.footer-attribution {
  font-size: 0.8rem;
  opacity: 0.85;
}

.footer-attribution a {
  color: var(--accent-cyan);
  font-weight: 500;
}

.footer-attribution a:hover {
  text-decoration: underline;
}

/* Legacy Scrollbar fallbacks - modern-web-guidance compliant */
@supports not (scrollbar-color: auto) {
  ::-webkit-scrollbar {
    width: 8px;
    height: 8px;
  }
  ::-webkit-scrollbar-track {
    background: var(--color-scrollbar-track);
  }
  ::-webkit-scrollbar-thumb {
    background: var(--color-scrollbar-thumb);
    border-radius: 4px;
  }
  ::-webkit-scrollbar-thumb:hover {
    background: var(--color-scrollbar-thumb-hover);
  }
}
