/* Midnight Flame Architecture Studio Theme - CSS */

/* CSS Custom Properties */
:root {
  --primary-color: #2C3E50;
  --secondary-color: #E74C3C;
  --dark-variant: #1a252f;
  --light-variant: #34495e;
  --accent-light: #f39c12;
  --text-dark: #2c3e50;
  --text-light: #ecf0f1;
  --text-muted: #7f8c8d;
  --bg-light: #f8f9fa;
  --bg-dark: #1a1a1a;
  --shadow-light: rgba(44, 62, 80, 0.1);
  --shadow-medium: rgba(44, 62, 80, 0.25);
  --shadow-dark: rgba(44, 62, 80, 0.5);
  --gradient-primary: linear-gradient(135deg, var(--primary-color) 0%, var(--dark-variant) 100%);
  --gradient-secondary: linear-gradient(135deg, var(--secondary-color) 0%, #c0392b 100%);
  --gradient-flame: linear-gradient(45deg, var(--secondary-color), var(--accent-light));
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.6;
  color: var(--text-dark);
  background-color: #ffffff;
  overflow-x: hidden;
}

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

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: 1.5rem;
  color: var(--text-muted);
  font-size: 1.1rem;
}

.lead {
  font-size: 1.25rem;
  font-weight: 400;
  color: var(--text-muted);
}

/* Bootstrap 5 Overrides */
.btn {
  border-radius: 0;
  padding: 0.875rem 2rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: 2px solid transparent;
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: var(--gradient-primary);
  border-color: var(--primary-color);
  color: white;
}

.btn-primary:hover,
.btn-primary:focus {
  background: var(--dark-variant);
  border-color: var(--dark-variant);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px var(--shadow-medium);
}

.btn-secondary {
  background: var(--gradient-secondary);
  border-color: var(--secondary-color);
  color: white;
}

.btn-secondary:hover,
.btn-secondary:focus {
  background: #c0392b;
  border-color: #c0392b;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(231, 76, 60, 0.3);
}

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

.btn-outline-primary:hover,
.btn-outline-primary:focus {
  background: var(--primary-color);
  border-color: var(--primary-color);
  color: white;
}

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

.btn-outline-secondary:hover,
.btn-outline-secondary:focus {
  background: var(--secondary-color);
  border-color: var(--secondary-color);
  color: white;
}

/* Navigation */
.navbar {
  padding: 1rem 0;
  transition: all 0.3s ease;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(44, 62, 80, 0.1);
}

.navbar.scrolled {
  padding: 0.5rem 0;
  box-shadow: 0 2px 20px var(--shadow-light);
}

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

.navbar-nav .nav-link {
  color: var(--primary-color);
  font-weight: 500;
  padding: 0.75rem 1.25rem;
  margin: 0 0.25rem;
  transition: all 0.3s ease;
  position: relative;
}

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

.navbar-nav .nav-link::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0;
  left: 50%;
  background: var(--gradient-flame);
  transition: all 0.3s ease;
}

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

.navbar-toggler {
  border: none;
  padding: 0.25rem 0.5rem;
}

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

/* Hero Section */
.hero {
  min-height: 100vh;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--dark-variant) 100%);
  position: relative;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero::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 1000 1000"><polygon fill="%23E74C3C" fill-opacity="0.1" points="0,1000 1000,0 1000,1000"/></svg>');
  background-size: cover;
}

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

.hero h1 {
  color: white;
  margin-bottom: 2rem;
  animation: fadeInUp 1s ease-out;
}

.hero .lead {
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 3rem;
  animation: fadeInUp 1s ease-out 0.2s both;
}

.hero-cta {
  animation: fadeInUp 1s ease-out 0.4s both;
}

/* Sections */
.section {
  padding: 6rem 0;
}

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

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

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

.section-bg-dark {
  background: var(--gradient-primary);
  color: white;
}

.section-bg-dark h2,
.section-bg-dark h3,
.section-bg-dark h4 {
  color: white;
}

.section-bg-dark p {
  color: rgba(255, 255, 255, 0.8);
}

/* Cards */
.card {
  border: none;
  border-radius: 0;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 20px var(--shadow-light);
  height: 100%;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px var(--shadow-medium);
}

.card-img-top {
  transition: all 0.3s ease;
  height: 250px;
  object-fit: cover;
}

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

.card-body {
  padding: 2rem;
}

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

.card-text {
  color: var(--text-muted);
  line-height: 1.6;
}

/* Service Cards */
.service-card {
  text-align: center;
  padding: 3rem 2rem;
  background: white;
  border-radius: 0;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

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

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

.service-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px var(--shadow-medium);
}

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

.service-card:hover .service-icon {
  background: var(--gradient-flame);
  transform: scale(1.1);
}

/* Portfolio Grid */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2rem;
}

.portfolio-item {
  position: relative;
  overflow: hidden;
  border-radius: 0;
  cursor: pointer;
}

.portfolio-item img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  transition: all 0.3s ease;
}

.portfolio-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(44, 62, 80, 0.9), rgba(231, 76, 60, 0.9));
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  opacity: 0;
  transition: all 0.3s ease;
  text-align: center;
  padding: 2rem;
}

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

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

.portfolio-overlay h4 {
  color: white;
  margin-bottom: 1rem;
}

.portfolio-overlay p {
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 0;
}

/* Forms */
.form-control {
  border: 2px solid #e9ecef;
  border-radius: 0;
  padding: 1rem 1.25rem;
  font-size: 1rem;
  transition: all 0.3s ease;
  background-color: #f8f9fa;
}

.form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(44, 62, 80, 0.1);
  background-color: white;
}

.form-label {
  font-weight: 600;
  color: var(--primary-color);
  margin-bottom: 0.75rem;
}

.form-group {
  margin-bottom: 2rem;
}

/* Contact Section */
.contact-info {
  background: white;
  padding: 3rem;
  box-shadow: 0 10px 30px var(--shadow-light);
  height: 100%;
}

.contact-item {
  display: flex;
  align-items: center;
  margin-bottom: 2rem;
}

.contact-icon {
  width: 50px;
  height: 50px;
  background: var(--gradient-flame);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 1.5rem;
  color: white;
  font-size: 1.25rem;
}

.contact-details h5 {
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.contact-details p {
  margin-bottom: 0;
  color: var(--text-muted);
}

/* Footer */
.footer {
  background: var(--gradient-primary);
  color: white;
  padding: 4rem 0 2rem;
}

.footer h5 {
  color: white;
  margin-bottom: 1.5rem;
}

.footer p,
.footer a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: color 0.3s ease;
}

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

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

/* Social Links */
.social-links {
  display: flex;
  gap: 1rem;
  justify-content: center;
}

.social-link {
  width: 45px;
  height: 45px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  text-decoration: none;
  transition: all 0.3s ease;
  font-size: 1.1rem;
}

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

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

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

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

.animate-on-scroll {
  opacity: 0;
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.fade-up {
  transform: translateY(30px);
}

.fade-up.animated {
  transform: translateY(0);
}

.fade-left {
  transform: translateX(-30px);
}

.fade-left.animated {
  transform: translateX(0);
}

.fade-right {
  transform: translateX(30px);
}

.fade-right.animated {
  transform: translateX(0);
}

/* Loading States */
.loading {
  position: relative;
  overflow: hidden;
}

.loading::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% { left: -100%; }
  100% { left: 100%; }
}

/* Responsive Design */
@media (max-width: 991.98px) {
  .navbar-nav {
    padding: 1rem 0;
    background: white;
    border-radius: 0;
    box-shadow: 0 4px 20px var(--shadow-light);
    margin-top: 1rem;
  }

  .navbar-nav .nav-link {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid rgba(44, 62, 80, 0.1);
  }

  .navbar-nav .nav-link:last-child {
    border-bottom: none;
  }

  .hero {
    min-height: 70vh;
    text-align: center;
  }

  .section {
    padding: 4rem 0;
  }

  .service-card {
    margin-bottom: 2rem;
  }

  .portfolio-grid {
    grid-template-columns: 1fr;
  }

  .contact-info {
    margin-bottom: 3rem;
  }
}

@media (max-width: 767.98px) {
  .btn {
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
  }

  .hero {
    min-height: 60vh;
    padding: 2rem 0;
  }

  .section {
    padding: 3rem 0;
  }

  .service-card,
  .contact-info {
    padding: 2rem 1.5rem;
  }

  .portfolio-grid {
    gap: 1rem;
  }

  .footer {
    padding: 3rem 0 1.5rem;
    text-align: center;
  }

  .social-links {
    margin-top: 2rem;
  }
}

@media (max-width: 575.98px) {
  .container-fluid {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  h1 {
    font-size: 2.25rem;
  }

  h2 {
    font-size: 1.875rem;
  }

  .btn {
    width: 100%;
    margin-bottom: 1rem;
  }

  .btn + .btn {
    margin-left: 0;
  }

  .service-card {
    padding: 1.5rem 1rem;
  }

  .contact-item {
    flex-direction: column;
    text-align: center;
  }

  .contact-icon {
    margin-right: 0;
    margin-bottom: 1rem;
  }
}

/* Print Styles */
@media print {
  .navbar,
  .btn,
  .footer {
    display: none;
  }

  body {
    font-size: 12pt;
    line-height: 1.4;
    color: black;
  }

  .hero {
    background: none;
    color: black;
    min-height: auto;
    padding: 2rem 0;
  }
}