/* Quantum Blaze Architecture Studio CSS */

/* CSS Custom Properties */
:root {
  --primary-color: #FF4500;
  --secondary-color: #1E3A8A;
  --primary-hover: #E63E00;
  --secondary-hover: #1E40AF;
  --text-dark: #1a1a1a;
  --text-light: #ffffff;
  --text-muted: #6c757d;
  --bg-light: #f8f9fa;
  --bg-dark: #212529;
  --border-color: #dee2e6;
  --shadow-sm: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
  --shadow-md: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
  --shadow-lg: 0 1rem 3rem rgba(0, 0, 0, 0.175);
  --gradient-primary: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  --gradient-overlay: linear-gradient(45deg, rgba(255, 69, 0, 0.9), rgba(30, 58, 138, 0.9));
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-heading: 'Space Grotesk', var(--font-primary);
}

/* Reset and Base Styles */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  line-height: 1.6;
  color: var(--text-dark);
  overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: -0.01em;
}

h3 {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
}

p {
  margin-bottom: 1rem;
  font-size: 1.1rem;
  line-height: 1.7;
}

/* Bootstrap 5 Overrides */
.btn {
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: 8px;
  padding: 12px 32px;
  transition: var(--transition);
  border: none;
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s;
}

.btn:hover::before {
  left: 100%;
}

.btn-primary {
  background: var(--primary-color);
  color: var(--text-light);
  box-shadow: var(--shadow-md);
}

.btn-primary:hover {
  background: var(--primary-hover);
  color: var(--text-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-secondary {
  background: var(--secondary-color);
  color: var(--text-light);
  box-shadow: var(--shadow-md);
}

.btn-secondary:hover {
  background: var(--secondary-hover);
  color: var(--text-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-outline-primary {
  border: 2px solid var(--primary-color);
  color: var(--primary-color);
  background: transparent;
}

.btn-outline-primary:hover {
  background: var(--primary-color);
  color: var(--text-light);
  border-color: var(--primary-color);
  transform: translateY(-2px);
}

.btn-outline-secondary {
  border: 2px solid var(--secondary-color);
  color: var(--secondary-color);
  background: transparent;
}

.btn-outline-secondary:hover {
  background: var(--secondary-color);
  color: var(--text-light);
  border-color: var(--secondary-color);
  transform: translateY(-2px);
}

/* Card Styles */
.card {
  border: none;
  border-radius: 16px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  overflow: hidden;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.card-img-top {
  transition: var(--transition);
}

.card:hover .card-img-top {
  transform: scale(1.05);
}

/* Navigation */
.navbar {
  background: rgba(255, 255, 255, 0.95) !important;
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: 1rem 0;
  transition: var(--transition);
}

.navbar.scrolled {
  background: rgba(255, 255, 255, 0.98) !important;
  box-shadow: var(--shadow-sm);
}

.navbar-brand {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 800;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-decoration: none;
}

.navbar-nav .nav-link {
  color: var(--text-dark) !important;
  font-weight: 500;
  margin: 0 8px;
  padding: 8px 16px !important;
  border-radius: 8px;
  transition: var(--transition);
  position: relative;
}

.navbar-nav .nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--primary-color);
  transition: var(--transition);
  transform: translateX(-50%);
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
  color: var(--primary-color) !important;
  background: rgba(255, 69, 0, 0.1);
}

.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after {
  width: 80%;
}

/* Mobile Menu Toggle */
.navbar-toggler {
  border: none;
  padding: 8px 12px;
  border-radius: 8px;
}

.navbar-toggler:focus {
  box-shadow: 0 0 0 3px rgba(255, 69, 0, 0.25);
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%23FF4500' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Hero Section */
.hero {
  min-height: 100vh;
  background: var(--gradient-overlay), url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 800"><defs><linearGradient id="grad" x1="0%" y1="0%" x2="100%" y2="100%"><stop offset="0%" style="stop-color:%231E3A8A;stop-opacity:0.1" /><stop offset="100%" style="stop-color:%23FF4500;stop-opacity:0.1" /></linearGradient></defs><rect width="1200" height="800" fill="url(%23grad)"/><g opacity="0.3"><circle cx="200" cy="200" r="2" fill="%23FF4500"/><circle cx="800" cy="150" r="3" fill="%231E3A8A"/><circle cx="600" cy="400" r="2" fill="%23FF4500"/><circle cx="1000" cy="300" r="2" fill="%231E3A8A"/><circle cx="300" cy="600" r="3" fill="%23FF4500"/></g></svg>');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 30% 50%, rgba(255, 69, 0, 0.1) 0%, transparent 50%),
              radial-gradient(circle at 70% 80%, rgba(30, 58, 138, 0.1) 0%, transparent 50%);
  animation: pulse 4s ease-in-out infinite;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero h1 {
  color: var(--text-light);
  margin-bottom: 2rem;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.25rem;
  margin-bottom: 2.5rem;
  max-width: 600px;
}

/* Floating Elements Animation */
.floating-elements {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.floating-element {
  position: absolute;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  animation: float 6s ease-in-out infinite;
}

.floating-element:nth-child(1) {
  width: 80px;
  height: 80px;
  top: 20%;
  left: 10%;
  animation-delay: 0s;
}

.floating-element:nth-child(2) {
  width: 60px;
  height: 60px;
  top: 60%;
  right: 20%;
  animation-delay: 2s;
}

.floating-element:nth-child(3) {
  width: 100px;
  height: 100px;
  bottom: 30%;
  left: 70%;
  animation-delay: 4s;
}

/* Section Styles */
.section {
  padding: 100px 0;
  position: relative;
}

.section-title {
  text-align: center;
  margin-bottom: 4rem;
  position: relative;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -20px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: var(--gradient-primary);
  border-radius: 2px;
}

.section-alt {
  background: var(--bg-light);
}

/* Project Grid */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.project-card {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  background: var(--text-light);
  box-shadow: var(--shadow-md);
  transition: var(--transition);
}

.project-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--gradient-overlay);
  opacity: 0;
  transition: var(--transition);
  z-index: 2;
}

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

.project-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-lg);
}

.project-image {
  height: 250px;
  background-size: cover;
  background-position: center;
  position: relative;
}

.project-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: var(--transition);
  z-index: 3;
}

.project-card:hover .project-overlay {
  opacity: 1;
}

.project-content {
  padding: 2rem;
}

.project-content h3 {
  color: var(--text-dark);
  margin-bottom: 1rem;
}

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

/* Services Grid */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.service-card {
  text-align: center;
  padding: 3rem 2rem;
  background: var(--text-light);
  border-radius: 16px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 4px;
  background: var(--gradient-primary);
  transition: var(--transition);
}

.service-card:hover::before {
  left: 0;
}

.service-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.service-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 2rem;
  background: var(--gradient-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: var(--text-light);
  transition: var(--transition);
}

.service-card:hover .service-icon {
  transform: scale(1.1) rotate(360deg);
}

/* Form Styles */
.form-control {
  border: 2px solid var(--border-color);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 1rem;
  transition: var(--transition);
}

.form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(255, 69, 0, 0.15);
}

.form-label {
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 8px;
}

.form-error {
  color: #dc3545;
  font-size: 0.875rem;
  margin-top: 4px;
}

.form-success {
  color: #198754;
  font-size: 0.875rem;
  margin-top: 4px;
}

/* Footer */
.footer {
  background: var(--bg-dark);
  color: var(--text-light);
  padding: 4rem 0 2rem;
}

.footer h5 {
  color: var(--text-light);
  margin-bottom: 1.5rem;
  position: relative;
}

.footer h5::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 40px;
  height: 2px;
  background: var(--primary-color);
}

.footer a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: var(--transition);
}

.footer a:hover {
  color: var(--primary-color);
}

.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
}

.social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  transition: var(--transition);
}

.social-link:hover {
  background: var(--primary-color);
  transform: translateY(-2px);
}

/* Animations */
@keyframes pulse {
  0%, 100% { opacity: 0.7; }
  50% { opacity: 1; }
}

@keyframes float {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  33% { transform: translateY(-20px) rotate(120deg); }
  66% { transform: translateY(-10px) rotate(240deg); }
}

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

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

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Animation Classes */
.animate-on-scroll {
  opacity: 0;
  transition: all 0.6s ease-out;
}

.animate-on-scroll.animate {
  opacity: 1;
}

.slide-up {
  animation: slideInUp 0.6s ease-out;
}

.slide-left {
  animation: slideInLeft 0.6s ease-out;
}

.slide-right {
  animation: slideInRight 0.6s ease-out;
}

/* Loading States */
.loading {
  position: relative;
  pointer-events: none;
}

.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top: 2px solid var(--text-light);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 768px) {
  .section {
    padding: 60px 0;
  }
  
  .hero {
    padding: 2rem 0;
    background-attachment: scroll;
  }
  
  .project-grid,
  .services-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .btn {
    padding: 10px 24px;
    font-size: 0.9rem;
  }
  
  .service-card {
    padding: 2rem 1.5rem;
  }
  
  .navbar-nav {
    background: rgba(255, 255, 255, 0.98);
    border-radius: 12px;
    margin-top: 1rem;
    padding: 1rem;
    box-shadow: var(--shadow-md);
  }
  
  .floating-element {
    display: none;
  }
}

@media (max-width: 576px) {
  :root {
    font-size: 14px;
  }
  
  .container {
    padding: 0 1rem;
  }
  
  .project-grid,
  .services-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .project-content,
  .service-card {
    padding: 1.5rem;
  }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
  :root {
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.3);
  }
  
  .btn-outline-primary,
  .btn-outline-secondary {
    border-width: 3px;
  }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  html {
    scroll-behavior: auto;
  }
}

/* Print Styles */
@media print {
  .navbar,
  .btn,
  .floating-elements {
    display: none !important;
  }
  
  .hero {
    background: none !important;
    color: black !important;
  }
  
  body {
    color: black !important;
    background: white !important;
  }
}