/* Storm & Thunder Architecture Studio CSS */

/* CSS Custom Properties */
:root {
  --primary-color: #2C3E50;
  --secondary-color: #E67E22;
  --accent-light: #34495E;
  --accent-dark: #1A252F;
  --text-light: #ECF0F1;
  --text-dark: #2C3E50;
  --white: #FFFFFF;
  --gray-light: #BDC3C7;
  --gray-dark: #7F8C8D;
  --storm-blue: #3498DB;
  --thunder-yellow: #F39C12;
  --gradient-primary: linear-gradient(135deg, var(--primary-color), var(--accent-light));
  --gradient-storm: linear-gradient(135deg, #2C3E50 0%, #3498DB 50%, #E67E22 100%);
  --shadow-light: 0 2px 10px rgba(44, 62, 80, 0.1);
  --shadow-medium: 0 5px 25px rgba(44, 62, 80, 0.15);
  --shadow-heavy: 0 10px 40px rgba(44, 62, 80, 0.2);
  --transition-fast: 0.3s ease;
  --transition-medium: 0.5s ease;
  --transition-slow: 0.8s ease;
}

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

body {
  font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: var(--text-dark);
  overflow-x: hidden;
  scroll-behavior: smooth;
}

html {
  scroll-behavior: smooth;
}

/* Bootstrap 5 Overrides */
.btn-primary {
  background: var(--gradient-primary);
  border: 2px solid var(--primary-color);
  color: var(--white);
  font-weight: 600;
  padding: 12px 30px;
  border-radius: 50px;
  transition: var(--transition-fast);
  position: relative;
  overflow: hidden;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.btn-primary:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-medium);
  color: var(--white);
}

.btn-primary:focus {
  box-shadow: 0 0 0 0.2rem rgba(44, 62, 80, 0.25);
  color: var(--white);
}

.btn-secondary {
  background: transparent;
  border: 2px solid var(--secondary-color);
  color: var(--secondary-color);
  font-weight: 600;
  padding: 12px 30px;
  border-radius: 50px;
  transition: var(--transition-fast);
  text-transform: uppercase;
  letter-spacing: 1px;
}

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

.btn-outline-light {
  border: 2px solid var(--white);
  color: var(--white);
  font-weight: 600;
  padding: 12px 30px;
  border-radius: 50px;
  transition: var(--transition-fast);
}

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

.card {
  border: none;
  border-radius: 15px;
  box-shadow: var(--shadow-light);
  transition: var(--transition-fast);
  overflow: hidden;
}

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

.card-header {
  background: var(--gradient-primary);
  color: var(--white);
  border: none;
  padding: 1.5rem;
}

.form-control {
  border: 2px solid var(--gray-light);
  border-radius: 10px;
  padding: 12px 15px;
  transition: var(--transition-fast);
  background: var(--white);
}

.form-control:focus {
  border-color: var(--secondary-color);
  box-shadow: 0 0 0 0.2rem rgba(230, 126, 34, 0.25);
  background: var(--white);
}

/* Navigation */
.navbar {
  background: rgba(44, 62, 80, 0.95) !important;
  backdrop-filter: blur(10px);
  padding: 1rem 0;
  transition: var(--transition-fast);
  box-shadow: var(--shadow-light);
}

.navbar.scrolled {
  background: rgba(44, 62, 80, 0.98) !important;
  box-shadow: var(--shadow-medium);
}

.navbar-brand {
  font-weight: 800;
  font-size: 1.8rem;
  color: var(--white) !important;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.navbar-brand:hover {
  color: var(--secondary-color) !important;
}

.navbar-nav .nav-link {
  color: var(--text-light) !important;
  font-weight: 500;
  margin: 0 15px;
  padding: 10px 0 !important;
  position: relative;
  transition: var(--transition-fast);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
  color: var(--secondary-color) !important;
}

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

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

.navbar-toggler {
  border: none;
  padding: 4px 8px;
}

.navbar-toggler:focus {
  box-shadow: none;
}

.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='rgba%28255, 255, 255, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='m4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Hero Section */
.hero-section {
  min-height: 100vh;
  background: var(--gradient-storm);
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="storm" patternUnits="userSpaceOnUse" width="100" height="100"><path d="M0,0 L50,50 L100,0 L100,100 L50,50 L0,100 Z" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23storm)"/></svg>') repeat;
  animation: storm-pattern 20s linear infinite;
}

@keyframes storm-pattern {
  0% { transform: translateX(0) translateY(0); }
  100% { transform: translateX(100px) translateY(100px); }
}

.hero-content {
  position: relative;
  z-index: 2;
  color: var(--white);
}

.hero-title {
  font-size: 4.5rem;
  font-weight: 900;
  margin-bottom: 2rem;
  text-transform: uppercase;
  letter-spacing: 3px;
  opacity: 0;
  animation: fadeInUp 1s ease forwards 0.5s;
}

.hero-subtitle {
  font-size: 1.5rem;
  font-weight: 300;
  margin-bottom: 3rem;
  opacity: 0;
  animation: fadeInUp 1s ease forwards 0.8s;
}

.hero-description {
  font-size: 1.2rem;
  margin-bottom: 3rem;
  line-height: 1.8;
  opacity: 0;
  animation: fadeInUp 1s ease forwards 1.1s;
}

.hero-buttons {
  opacity: 0;
  animation: fadeInUp 1s ease forwards 1.4s;
}

.hero-buttons .btn {
  margin: 0 15px 15px 0;
}

/* Lightning Effect */
.lightning {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0;
  animation: lightning-flash 8s ease-in-out infinite;
}

.lightning::before {
  content: '';
  position: absolute;
  top: 10%;
  left: 20%;
  width: 2px;
  height: 200px;
  background: linear-gradient(to bottom, transparent, var(--thunder-yellow), transparent);
  transform: rotate(15deg);
  opacity: 0;
  animation: lightning-bolt 0.3s ease-in-out infinite;
}

@keyframes lightning-flash {
  0%, 90%, 100% { opacity: 0; }
  91%, 95% { opacity: 0.8; }
}

@keyframes lightning-bolt {
  0%, 90%, 100% { opacity: 0; }
  91%, 95% { opacity: 1; }
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

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

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

.section-title {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--primary-color);
  text-align: center;
  position: relative;
  text-transform: uppercase;
  letter-spacing: 2px;
}

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

.section-subtitle {
  font-size: 1.2rem;
  color: var(--gray-dark);
  text-align: center;
  margin-bottom: 4rem;
  font-weight: 300;
}

/* About Section */
.about-section {
  background: var(--text-light);
}

.about-card {
  background: var(--white);
  padding: 3rem;
  border-radius: 20px;
  box-shadow: var(--shadow-light);
  transition: var(--transition-fast);
  height: 100%;
}

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

.about-icon {
  font-size: 3rem;
  color: var(--secondary-color);
  margin-bottom: 2rem;
}

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

/* Services Section */
.services-section {
  background: var(--white);
}

.service-card {
  background: var(--white);
  padding: 2.5rem;
  border-radius: 15px;
  box-shadow: var(--shadow-light);
  transition: var(--transition-medium);
  border: 1px solid rgba(44, 62, 80, 0.1);
  height: 100%;
  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-medium);
}

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

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

.service-icon {
  font-size: 3.5rem;
  color: var(--secondary-color);
  margin-bottom: 2rem;
  display: block;
  transition: var(--transition-fast);
}

.service-card:hover .service-icon {
  transform: scale(1.1);
  color: var(--primary-color);
}

.service-title {
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.service-description {
  color: var(--gray-dark);
  line-height: 1.7;
}

/* Portfolio Section */
.portfolio-section {
  background: var(--text-light);
}

.portfolio-item {
  position: relative;
  overflow: hidden;
  border-radius: 15px;
  box-shadow: var(--shadow-light);
  transition: var(--transition-medium);
  margin-bottom: 2rem;
}

.portfolio-item:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-heavy);
}

.portfolio-image {
  width: 100%;
  height: 300px;
  object-fit: cover;
  transition: var(--transition-medium);
}

.portfolio-item:hover .portfolio-image {
  transform: scale(1.1);
}

.portfolio-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(44, 62, 80, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  opacity: 0;
  transition: var(--transition-fast);
}

.portfolio-item:hover .portfolio-overlay {
  opacity: 1;
}

.portfolio-title {
  color: var(--white);
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
  text-align: center;
}

.portfolio-category {
  color: var(--secondary-color);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Contact Section */
.contact-section {
  background: var(--gradient-primary);
  color: var(--white);
}

.contact-section .section-title {
  color: var(--white);
}

.contact-section .section-title::after {
  background: var(--secondary-color);
}

.contact-section .section-subtitle {
  color: var(--text-light);
}

.contact-card {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 3rem;
  border-radius: 20px;
  transition: var(--transition-fast);
}

.contact-card:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-5px);
}

.contact-icon {
  font-size: 2.5rem;
  color: var(--secondary-color);
  margin-bottom: 1.5rem;
}

.contact-title {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--white);
}

.contact-info {
  color: var(--text-light);
  font-size: 1rem;
}

.contact-form {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  padding: 3rem;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.contact-form .form-control {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: var(--text-dark);
}

.contact-form .form-control:focus {
  background: var(--white);
  border-color: var(--secondary-color);
}

.contact-form .form-control::placeholder {
  color: var(--gray-dark);
}

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

.footer-title {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 2rem;
  color: var(--white);
  position: relative;
}

.footer-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 50px;
  height: 2px;
  background: var(--secondary-color);
}

.footer-link {
  color: var(--text-light);
  text-decoration: none;
  transition: var(--transition-fast);
  display: block;
  padding: 5px 0;
}

.footer-link:hover {
  color: var(--secondary-color);
  transform: translateX(5px);
}

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

.social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 45px;
  height: 45px;
  background: rgba(230, 126, 34, 0.2);
  color: var(--secondary-color);
  border-radius: 50%;
  text-decoration: none;
  transition: var(--transition-fast);
  font-size: 1.2rem;
}

.social-link:hover {
  background: var(--secondary-color);
  color: var(--white);
  transform: translateY(-3px);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 3rem;
  padding-top: 2rem;
  text-align: center;
  color: var(--gray-light);
}

/* Utility Classes */
.text-primary-custom {
  color: var(--primary-color) !important;
}

.text-secondary-custom {
  color: var(--secondary-color) !important;
}

.bg-primary-custom {
  background-color: var(--primary-color) !important;
}

.bg-secondary-custom {
  background-color: var(--secondary-color) !important;
}

.bg-gradient-custom {
  background: var(--gradient-primary) !important;
}

/* Loading Animation */
.loading {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--gradient-storm);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s ease;
}

.loading.hidden {
  opacity: 0;
  pointer-events: none;
}

.storm-loader {
  width: 60px;
  height: 60px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-top: 3px solid var(--secondary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

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

/* Scroll to Top */
.scroll-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: var(--gradient-primary);
  color: var(--white);
  border: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-fast);
  z-index: 1000;
  box-shadow: var(--shadow-medium);
}

.scroll-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.scroll-to-top:hover {
  transform: translateY(-3px);
  background: var(--accent-dark);
}

/* Responsive Design */
@media (max-width: 768px) {
  .hero-title {
    font-size: 2.5rem;
  }
  
  .hero-subtitle {
    font-size: 1.2rem;
  }
  
  .hero-description {
    font-size: 1rem;
  }
  
  .section {
    padding: 60px 0;
  }
  
  .section-title {
    font-size: 2rem;
  }
  
  .about-card,
  .service-card,
  .contact-card,
  .contact-form {
    padding: 2rem;
    margin-bottom: 2rem;
  }
  
  .navbar-nav {
    background: rgba(44, 62, 80, 0.95);
    padding: 1rem;
    border-radius: 10px;
    margin-top: 1rem;
  }
  
  .navbar-nav .nav-link {
    margin: 5px 0;
    padding: 10px 15px !important;
    border-radius: 5px;
  }
  
  .navbar-nav .nav-link:hover {
    background: rgba(230, 126, 34, 0.1);
  }
  
  .hero-buttons .btn {
    display: block;
    width: 100%;
    margin: 0 0 15px 0;
  }
}

@media (max-width: 576px) {
  .hero-title {
    font-size: 2rem;
    letter-spacing: 1px;
  }
  
  .section-title {
    font-size: 1.8rem;
  }
  
  .portfolio-image {
    height: 250px;
  }
  
  .about-card,
  .service-card,
  .contact-card,
  .contact-form {
    padding: 1.5rem;
  }
  
  .scroll-to-top {
    bottom: 20px;
    right: 20px;
    width: 45px;
    height: 45px;
  }
}

/* High contrast and accessibility */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Focus styles for accessibility */
.btn:focus,
.form-control:focus,
.nav-link:focus {
  outline: 2px solid var(--secondary-color);
  outline-offset: 2px;
}

/* Print styles */
@media print {
  .navbar,
  .hero-section,
  .scroll-to-top,
  .loading {
    display: none !important;
  }
  
  .section {
    padding: 20px 0;
  }
  
  * {
    background: white !important;
    color: black !important;
  }
}