/* =========================================
   SCRIBES GLOBAL - MAIN CSS
   Mobile-First Responsive Design
   ========================================= */

/* Import Google Fonts - Playful & Modern */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800;900&family=Playfair+Display:wght@400;500;600;700;800;900&family=Caveat:wght@400;500;600;700&family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

/* Tailwind CSS CDN */
@import url('https://cdn.jsdelivr.net/npm/tailwindcss@3.4.1/base.min.css');

/* =========================================
   CSS VARIABLES - SCRIBES GLOBAL COLORS
   ========================================= */
:root {
  /* Primary Colors from Scribes Global */
  --primary-purple: #6B46C1;
  --primary-gold: #D4AF37;
  --primary-teal: #2D9CDB;
  --primary-coral: #EB5757;
  
  /* Secondary Colors */
  --secondary-purple-light: #9B7EDE;
  --secondary-purple-dark: #4A2F8A;
  --secondary-gold-light: #F2D97A;
  --secondary-teal-light: #56CCF2;
  
  /* Neutral Colors */
  --dark-bg: #1A1A2E;
  --dark-secondary: #16213E;
  --dark-accent: #0F3460;
  --light-bg: #F8F9FA;
  --white: #FFFFFF;
  --gray-100: #F7FAFC;
  --gray-200: #EDF2F7;
  --gray-300: #E2E8F0;
  --gray-400: #CBD5E0;
  --gray-500: #A0AEC0;
  --gray-600: #718096;
  --gray-700: #4A5568;
  --gray-800: #2D3748;
  --gray-900: #1A202C;
  
  /* Badge Colors */
  --badge-gold: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
  --badge-red: linear-gradient(135deg, #FF6B6B 0%, #C92A2A 100%);
  --badge-purple: linear-gradient(135deg, #9B7EDE 0%, #6B46C1 100%);
  --badge-pink: linear-gradient(135deg, #FF69B4 0%, #FF1493 100%);
  --badge-green: linear-gradient(135deg, #51CF66 0%, #2F9E44 100%);
  --badge-silver: linear-gradient(135deg, #C0C0C0 0%, #808080 100%);
  
  /* Typography */
  --font-primary: 'Poppins', sans-serif;
  --font-heading: 'Playfair Display', serif;
  --font-accent: 'Caveat', cursive;
  --font-mono: 'Space Grotesk', monospace;
  
  /* Spacing */
  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 3rem;
  --spacing-3xl: 4rem;
  
  /* Border Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
  --radius-full: 9999px;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  
  /* Transitions */
  --transition-fast: 150ms ease-in-out;
  --transition-base: 300ms ease-in-out;
  --transition-slow: 500ms ease-in-out;
}

/* =========================================
   RESET & BASE STYLES
   ========================================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-primary);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--gray-800);
  background-color: var(--light-bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  color: var(--dark-bg);
  margin-bottom: var(--spacing-md);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
  margin-bottom: var(--spacing-md);
}

a {
  color: var(--primary-purple);
  text-decoration: none;
  transition: all var(--transition-base);
}

a:hover {
  color: var(--secondary-purple-dark);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* =========================================
   UTILITY CLASSES
   ========================================= */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.container-fluid {
  width: 100%;
  padding: 0 1rem;
}

.section {
  padding: 3rem 0;
}

.section-dark {
  background-color: var(--dark-bg);
  color: var(--white);
}

.text-center {
  text-align: center;
}

.text-gradient {
  background: linear-gradient(135deg, var(--primary-purple) 0%, var(--primary-teal) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  border-radius: var(--radius-lg);
  border: none;
  cursor: pointer;
  transition: all var(--transition-base);
  text-decoration: none;
  font-family: var(--font-primary);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-purple) 0%, var(--secondary-purple-light) 100%);
  color: var(--white);
  box-shadow: var(--shadow-md);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  color: var(--white);
}

.btn-secondary {
  background: linear-gradient(135deg, var(--primary-gold) 0%, var(--secondary-gold-light) 100%);
  color: var(--dark-bg);
  box-shadow: var(--shadow-md);
}

.btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  color: var(--dark-bg);
}

.btn-outline {
  background: transparent;
  color: var(--primary-purple);
  border: 2px solid var(--primary-purple);
}

.btn-outline:hover {
  background: var(--primary-purple);
  color: var(--white);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

.btn-lg {
  padding: 1rem 2rem;
  font-size: 1.125rem;
}

/* =========================================
   NAVIGATION
   ========================================= */
.navbar {
  position: sticky;
  top: 0;
  width: 100%;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-md);
  z-index: 1000;
  transition: all var(--transition-base);
}

.navbar-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem;
  max-width: 1400px;
  margin: 0 auto;
}

.navbar-logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.5rem;
  font-weight: 800;
  font-family: var(--font-heading);
  color: var(--primary-purple);
}

.navbar-logo img {
  height: 50px;
  width: auto;
}

.navbar-menu {
  display: none;
  list-style: none;
  gap: 2rem;
  align-items: center;
}

.navbar-menu li {
  position: relative;
}

.navbar-menu a {
  color: var(--gray-700);
  font-weight: 500;
  padding: 0.5rem 0;
  transition: color var(--transition-base);
}

.navbar-menu a:hover {
  color: var(--primary-purple);
}

.dropdown {
  position: relative;
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--white);
  box-shadow: var(--shadow-xl);
  border-radius: var(--radius-lg);
  padding: 1rem 0;
  min-width: 200px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all var(--transition-base);
}

.dropdown:hover .dropdown-menu,
.dropdown-menu.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-menu a {
  display: block;
  padding: 0.75rem 1.5rem;
  color: var(--gray-700);
  transition: all var(--transition-fast);
}

.dropdown-menu a:hover {
  background: var(--gray-100);
  color: var(--primary-purple);
  padding-left: 2rem;
}

.navbar-cta {
  background: linear-gradient(135deg, var(--primary-gold) 0%, var(--secondary-gold-light) 100%);
  color: var(--dark-bg) !important;
  padding: 0.5rem 1.5rem;
  border-radius: var(--radius-full);
  font-weight: 600;
}

.navbar-cta:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-lg);
}

.hamburger {
  display: flex;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
  padding: 0.5rem;
}

.hamburger span {
  width: 25px;
  height: 3px;
  background: var(--primary-purple);
  border-radius: 2px;
  transition: all var(--transition-base);
}

.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(7px, 7px);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -7px);
}

/* Mobile Menu */
.mobile-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 80%;
  max-width: 400px;
  height: 100vh;
  background: var(--white);
  box-shadow: var(--shadow-2xl);
  padding: 2rem;
  overflow-y: auto;
  transition: right var(--transition-slow);
  z-index: 999;
}

.mobile-menu.active {
  right: 0;
}

.mobile-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
  z-index: 998;
}

.mobile-overlay.active {
  opacity: 1;
  visibility: visible;
}

.mobile-menu-list {
  list-style: none;
  margin-top: 2rem;
}

.mobile-menu-list li {
  margin-bottom: 1rem;
}

.mobile-menu-list a {
  display: block;
  padding: 0.75rem 0;
  font-size: 1.125rem;
  color: var(--gray-700);
  font-weight: 500;
}

.mobile-dropdown-toggle {
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
}

.mobile-dropdown-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition-base);
  padding-left: 1rem;
}

.mobile-dropdown-content.active {
  max-height: 500px;
}

.mobile-dropdown-content a {
  font-size: 1rem;
  padding: 0.5rem 0;
}

/* =========================================
   FOOTER
   ========================================= */
.footer {
  background: var(--dark-bg);
  color: var(--gray-300);
  padding: 3rem 0 1rem;
}

.footer-content {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h4 {
  color: var(--white);
  font-size: 1.25rem;
  margin-bottom: 1rem;
  font-family: var(--font-heading);
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 0.5rem;
}

.footer-section a {
  color: var(--gray-400);
  transition: color var(--transition-base);
}

.footer-section a:hover {
  color: var(--primary-gold);
}

.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
}

.social-links a {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--dark-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  transition: all var(--transition-base);
}

.social-links a:hover {
  background: var(--primary-purple);
  transform: translateY(-3px);
}

.footer-bottom {
  border-top: 1px solid var(--dark-accent);
  padding-top: 1.5rem;
  text-align: center;
  font-size: 0.875rem;
  color: var(--gray-500);
}

/* =========================================
   BADGES & USER TAGS
   ========================================= */
.user-display {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.name-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--white);
}

/* Role-based gradient badges */
.poet-badge { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); }
.worship-badge { background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%); }
.teacher-badge { background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%); }
.intercessor-badge { background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%); }
.writer-badge { background: linear-gradient(135deg, #fa709a 0%, #fee140 100%); }
.creative-badge { background: linear-gradient(135deg, #30cfd0 0%, #330867 100%); }
.evangelist-badge { background: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%); }
.ministry-leader-badge { background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 100%); }
.volunteer-badge { background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%); }
.member-badge { background: linear-gradient(135deg, #e0c3fc 0%, #8ec5fc 100%); }

.role-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.75rem;
  background: var(--primary-purple);
  color: var(--white);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 500;
}

.chapter-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.75rem;
  background: var(--gray-200);
  color: var(--gray-700);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 500;
}

.team-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.75rem;
  background: var(--primary-teal);
  color: var(--white);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 500;
}

.verified-badge {
  display: inline-block;
  width: 20px;
  height: 20px;
  position: relative;
}

.verified-badge svg {
  width: 100%;
  height: 100%;
}

/* Badge color variations */
.badge-gold path { fill: #FFD700; }
.badge-gold circle { fill: #FFA500; }

.badge-red path { fill: #FF6B6B; }
.badge-red circle { fill: #C92A2A; }

.badge-purple path { fill: #9B7EDE; }
.badge-purple circle { fill: #6B46C1; }

.badge-pink path { fill: #FF69B4; }
.badge-pink circle { fill: #FF1493; }

.badge-green path { fill: #51CF66; }
.badge-green circle { fill: #2F9E44; }

.badge-silver path { fill: #C0C0C0; }
.badge-silver circle { fill: #808080; }

/* Profile sizes */
.verified-badge.lg {
  width: 24px;
  height: 24px;
}

.verified-badge.xl {
  width: 32px;
  height: 32px;
}

/* Tooltip for badges */
.badge-tooltip {
  position: relative;
  cursor: help;
}

.badge-tooltip::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 125%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--dark-bg);
  color: var(--white);
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-md);
  font-size: 0.75rem;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
  pointer-events: none;
  z-index: 10;
}

.badge-tooltip:hover::after {
  opacity: 1;
  visibility: visible;
}

/* =========================================
   FORMS
   ========================================= */
.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--gray-700);
}

.form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  font-family: var(--font-primary);
  border: 2px solid var(--gray-300);
  border-radius: var(--radius-md);
  background: var(--white);
  transition: all var(--transition-base);
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-purple);
  box-shadow: 0 0 0 3px rgba(107, 70, 193, 0.1);
}

.form-control.error {
  border-color: var(--primary-coral);
}

.form-error {
  color: var(--primary-coral);
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

textarea.form-control {
  min-height: 120px;
  resize: vertical;
}

.checkbox-group,
.radio-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.checkbox-group input,
.radio-group input {
  width: 18px;
  height: 18px;
  cursor: pointer;
}

/* =========================================
   CARDS
   ========================================= */
.card {
  background: var(--white);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  transition: all var(--transition-base);
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-xl);
}

.card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.card-body {
  padding: 1.5rem;
}

.card-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--dark-bg);
}

.card-text {
  color: var(--gray-600);
  margin-bottom: 1rem;
}

.card-footer {
  padding: 1rem 1.5rem;
  background: var(--gray-100);
  border-top: 1px solid var(--gray-200);
}

/* =========================================
   LOADING & ANIMATIONS
   ========================================= */
.spinner {
  border: 3px solid var(--gray-200);
  border-top: 3px solid var(--primary-purple);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.fade-in {
  animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.slide-up {
  animation: slideUp 0.5s ease-out;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================================
   RESPONSIVE BREAKPOINTS
   ========================================= */

/* Tablet (768px and up) */
@media (min-width: 768px) {
  h1 { font-size: 3rem; }
  h2 { font-size: 2.5rem; }
  h3 { font-size: 2rem; }
  
  .navbar-menu {
    display: flex;
  }
  
  .hamburger {
    display: none;
  }
  
  .footer-content {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .section {
    padding: 4rem 0;
  }
}

/* Desktop (1024px and up) */
@media (min-width: 1024px) {
  html {
    font-size: 18px;
  }
  
  .container {
    padding: 0 2rem;
  }
  
  .footer-content {
    grid-template-columns: repeat(4, 1fr);
  }
  
  .section {
    padding: 5rem 0;
  }
}

/* Large Desktop (1280px and up) */
@media (min-width: 1280px) {
  .container {
    max-width: 1400px;
  }
}

/* =========================================
   ACCESSIBILITY
   ========================================= */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

:focus-visible {
  outline: 3px solid var(--primary-purple);
  outline-offset: 2px;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}