/* Industrial Forge Architecture Studio Theme */
/* Primary Color: #2C3E50 | Secondary Color: #E74C3C */

/* ==================== CSS VARIABLES ==================== */
:root {
  --primary-color: #2C3E50;
  --secondary-color: #E74C3C;
  --accent-color: #95A5A6;
  --dark-color: #1A252F;
  --light-color: #ECF0F1;
  --text-dark: #2C3E50;
  --text-light: #7F8C8D;
  --white: #FFFFFF;
  --transition-base: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  --shadow-sm: 0 2px 8px rgba(44, 62, 80, 0.08);
  --shadow-md: 0 4px 16px rgba(44, 62, 80, 0.12);
  --shadow-lg: 0 8px 32px rgba(44, 62, 80, 0.16);
  --border-radius: 2px;
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-heading: 'Montserrat', 'Inter', sans-serif;
}

/* ==================== GLOBAL STYLES ==================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-primary);
  color: var(--text-dark);
  line-height: 1.7;
  overflow-x: hidden;
  background-color: var(--white);
  -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(--primary-color);
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 800;
}

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

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

h4 {
  font-size: clamp(1.25rem, 2.5vw, 1.5rem);
}

p {
  margin-bottom: 1rem;
  color: var(--text-light);
}

a {
  text-decoration: none;
  transition: var(--transition-base);
}

/* ==================== BOOTSTRAP 5 OVERRIDES ==================== */
.btn {
  padding: 0.875rem 2rem;
  font-weight: 600;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: var(--border-radius);
  border: 2px solid transparent;
  transition: var(--transition-base);
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.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: var(--transition-smooth);
  z-index: -1;
}

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

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

.btn-primary:hover,
.btn-primary:focus {
  background-color: #C0392B;
  border-color: #C0392B;
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-primary:active {
  background-color: #A93226;
  border-color: #A93226;
  transform: translateY(0);
}

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

.btn-outline-primary:hover,
.btn-outline-primary:focus {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

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

.btn-secondary:hover,
.btn-secondary:focus {
  background-color: var(--dark-color);
  border-color: var(--dark-color);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-lg {
  padding: 1.125rem 2.5rem;
  font-size: 1rem;
}

.btn-sm {
  padding: 0.625rem 1.5rem;
  font-size: 0.85rem;
}

/* ==================== NAVIGATION ==================== */
.navbar {
  padding: 1.5rem 0;
  background-color: var(--white);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-base);
}

.navbar.scrolled {
  padding: 1rem 0;
  box-shadow: var(--shadow-md);
}

.navbar-brand {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary-color);
  letter-spacing: -0.5px;
  position: relative;
}

.navbar-brand::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 3px;
  background-color: var(--secondary-color);
  transition: var(--transition-base);
}

.navbar-brand:hover::after {
  width: 100%;
}

.navbar-brand:hover,
.navbar-brand:focus {
  color: var(--secondary-color);
}

.navbar-nav .nav-link {
  color: var(--text-dark);
  font-weight: 500;
  padding: 0.5rem 1.25rem;
  margin: 0 0.25rem;
  position: relative;
  transition: var(--transition-base);
}

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

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

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

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

.navbar-toggler {
  border: none;
  padding: 0.5rem;
  position: relative;
  width: 30px;
  height: 24px;
}

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

.navbar-toggler-icon {
  background-image: none;
  position: relative;
  transition: var(--transition-base);
}

.navbar-toggler span {
  display: block;
  width: 30px;
  height: 3px;
  background-color: var(--primary-color);
  position: absolute;
  left: 0;
  transition: var(--transition-base);
  border-radius: 2px;
}

.navbar-toggler span:nth-child(1) {
  top: 0;
}

.navbar-toggler span:nth-child(2) {
  top: 50%;
  transform: translateY(-50%);
}

.navbar-toggler span:nth-child(3) {
  bottom: 0;
}

.navbar-toggler.active span:nth-child(1) {
  top: 50%;
  transform: translateY(-50%) rotate(45deg);
}

.navbar-toggler.active span:nth-child(2) {
  opacity: 0;
}

.navbar-toggler.active span:nth-child(3) {
  bottom: 50%;
  transform: translateY(50%) rotate(-45deg);
}

/* ==================== HERO SECTION ==================== */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--dark-color) 100%);
  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 width="100" height="100" xmlns="http://www.w3.org/2000/svg"><rect width="100" height="100" fill="none"/><path d="M0 0L100 100M100 0L0 100" stroke="rgba(255,255,255,0.03)" stroke-width="1"/></svg>');
  background-size: 100px 100px;
  opacity: 0.5;
}

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

.hero-title {
  color: var(--white);
  margin-bottom: 1.5rem;
  animation: fadeInUp 0.8s ease-out;
}

.hero-subtitle {
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  color: var(--light-color);
  margin-bottom: 2rem;
  animation: fadeInUp 0.8s ease-out 0.2s both;
}

.hero-buttons {
  animation: fadeInUp 0.8s ease-out 0.4s both;
}

.hero-image {
  position: relative;
  animation: fadeInRight 1s ease-out 0.3s both;
}

.hero-image img {
  max-width: 100%;
  height: auto;
  filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.3));
}

/* ==================== SECTION STYLES ==================== */
section {
  padding: 5rem 0;
  position: relative;
}

.section-title {
  position: relative;
  margin-bottom: 1rem;
  display: inline-block;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--secondary-color), var(--accent-color));
  border-radius: 2px;
}

.section-subtitle {
  color: var(--text-light);
  font-size: 1.125rem;
  margin-bottom: 3rem;
}

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

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

.bg-dark-section h1,
.bg-dark-section h2,
.bg-dark-section h3,
.bg-dark-section h4,
.bg-dark-section h5,
.bg-dark-section h6 {
  color: var(--white);
}

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

/* ==================== CARDS ==================== */
.card {
  border: none;
  border-radius: var(--border-radius);
  overflow: hidden;
  transition: var(--transition-base);
  box-shadow: var(--shadow-sm);
  height: 100%;
}

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

.card-img-top {
  transition: var(--transition-smooth);
  height: 250px;
  object-fit: cover;
}

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

.card-body {
  padding: 1.5rem;
}

.card-title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  color: var(--primary-color);
}

.card-text {
  color: var(--text-light);
  margin-bottom: 1rem;
}

.card-link {
  color: var(--secondary-color);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.875rem;
  letter-spacing: 0.5px;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.card-link:hover,
.card-link:focus {
  color: var(--primary-color);
  gap: 0.75rem;
}

/* ==================== PROJECT CARDS ==================== */
.project-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--border-radius);
  cursor: pointer;
  height: 400px;
}

.project-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition-smooth);
}

.project-card-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to top, rgba(44, 62, 80, 0.95) 0%, transparent 100%);
  opacity: 0;
  transition: var(--transition-base);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 2rem;
}

.project-card:hover .project-card-img {
  transform: scale(1.1);
}

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

.project-card-title {
  color: var(--white);
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
  transform: translateY(20px);
  transition: var(--transition-base);
}

.project-card-category {
  color: var(--secondary-color);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.875rem;
  letter-spacing: 1px;
  transform: translateY(20px);
  transition: var(--transition-base) 0.1s;
}

.project-card:hover .project-card-title,
.project-card:hover .project-card-category {
  transform: translateY(0);
}

/* ==================== SERVICES ==================== */
.service-item {
  padding: 2.5rem 2rem;
  background-color: var(--white);
  border-radius: var(--border-radius);
  transition: var(--transition-base);
  box-shadow: var(--shadow-sm);
  text-align: center;
  height: 100%;
}

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

.service-icon {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, var(--secondary-color), #C0392B);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  font-size: 2rem;
  color: var(--white);
  transition: var(--transition-base);
}

.service-item:hover .service-icon {
  transform: rotateY(360deg);
}

.service-title {
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.service-description {
  color: var(--text-light);
  line-height: 1.6;
}

/* ==================== TEAM MEMBERS ==================== */
.team-member {
  text-align: center;
  transition: var(--transition-base);
}

.team-member-img-wrapper {
  position: relative;
  overflow: hidden;
  border-radius: var(--border-radius);
  margin-bottom: 1.5rem;
}

.team-member-img {
  width: 100%;
  height: auto;
  transition: var(--transition-smooth);
  display: block;
}

.team-member:hover .team-member-img {
  transform: scale(1.05);
}

.team-social {
  position: absolute;
  bottom: -50px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 1rem;
  padding: 1rem;
  background: linear-gradient(to top, rgba(44, 62, 80, 0.9), transparent);
  transition: var(--transition-base);
}

.team-member:hover .team-social {
  bottom: 0;
}

.team-social a {
  width: 40px;
  height: 40px;
  background-color: var(--white);
  color: var(--primary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-base);
}

.team-social a:hover,
.team-social a:focus {
  background-color: var(--secondary-color);
  color: var(--white);
  transform: translateY(-3px);
}

.team-member-name {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}

.team-member-role {
  color: var(--secondary-color);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.875rem;
  letter-spacing: 0.5px;
}

/* ==================== FORMS ==================== */
.form-control,
.form-select {
  padding: 0.875rem 1.25rem;
  border: 2px solid var(--light-color);
  border-radius: var(--border-radius);
  font-size: 0.95rem;
  transition: var(--transition-base);
  background-color: var(--white);
  color: var(--text-dark);
}

.form-control:focus,
.form-select:focus {
  border-color: var(--secondary-color);
  box-shadow: 0 0 0 0.2rem rgba(231, 76, 60, 0.15);
  outline: none;
}

.form-control.is-invalid {
  border-color: var(--secondary-color);
}

.form-control.is-valid {
  border-color: #27AE60;
}

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

.invalid-feedback {
  color: var(--secondary-color);
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

.valid-feedback {
  color: #27AE60;
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

textarea.form-control {
  min-height: 150px;
  resize: vertical;
}

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

.footer h5 {
  color: var(--white);
  font-size: 1.125rem;
  margin-bottom: 1.5rem;
  position: relative;
  padding-bottom: 0.75rem;
}

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

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 0.75rem;
}

.footer-links a {
  color: var(--light-color);
  transition: var(--transition-base);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-links a:hover,
.footer-links a:focus {
  color: var(--secondary-color);
  padding-left: 0.5rem;
}

.footer-social {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.footer-social a {
  width: 45px;
  height: 45px;
  background-color: rgba(255, 255, 255, 0.1);
  color: var(--white);
  border-radius: var(--border-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-base);
  font-size: 1.125rem;
}

.footer-social a:hover,
.footer-social a:focus {
  background-color: var(--secondary-color);
  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(--accent-color);
}

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

.footer-bottom a:hover,
.footer-bottom a:focus {
  color: var(--white);
}

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

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

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

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

.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: var(--transition-smooth);
}

.animate-on-scroll.animated {
  opacity: 1;
  transform: translateY(0);
}

/* ==================== UTILITIES ==================== */
.text-primary-custom {
  color: var(--primary-color);
}

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

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

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

.divider {
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--secondary-color), var(--accent-color));
  border-radius: 2px;
  margin: 1rem 0;
}

.divider-center {
  margin-left: auto;
  margin-right: auto;
}

/* ==================== LOADING SPINNER ==================== */
.loading-spinner {
  display: inline-block;
  width: 40px;
  height: 40px;
  border: 4px solid var(--light-color);
  border-top-color: var(--secondary-color);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ==================== BACK TO TOP BUTTON ==================== */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background-color: var(--secondary-color);
  color: var(--white);
  border: none;
  border-radius: var(--border-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-base);
  box-shadow: var(--shadow-md);
  z-index: 999;
}

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

.back-to-top:hover,
.back-to-top:focus {
  background-color: var(--primary-color);
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

/* ==================== RESPONSIVE DESIGN ==================== */
@media (max-width: 991.98px) {
  .navbar-collapse {
    background-color: var(--white);
    padding: 1.5rem;
    margin-top: 1rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
  }

  .navbar-nav .nav-link {
    padding: 0.75rem 0;
  }

  .navbar-nav .nav-link::before {
    left: 0;
    transform: translateX(0);
  }

  .hero-section {
    min-height: auto;
    padding: 4rem 0;
  }

  section {
    padding: 3rem 0;
  }

  .project-card {
    height: 300px;
  }
}

@media (max-width: 767.98px) {
  h1 {
    font-size: 2.25rem;
  }

  h2 {
    font-size: 1.875rem;
  }

  .btn {
    padding: 0.75rem 1.5rem;
    font-size: 0.875rem;
  }

  .service-item {
    padding: 2rem 1.5rem;
  }

  .service-icon {
    width: 60px;
    height: 60px;
    font-size: 1.5rem;
  }

  .back-to-top {
    width: 45px;
    height: 45px;
    bottom: 20px;
    right: 20px;
  }

  .footer {
    padding: 3rem 0 1.5rem;
  }
}

@media (max-width: 575.98px) {
  .hero-buttons .btn {
    display: block;
    width: 100%;
    margin-bottom: 1rem;
  }

  .project-card {
    height: 250px;
  }

  .card-img-top {
    height: 200px;
  }
}