/* Architectural Studio - Midnight Steel & Forge Orange Theme */
/* Modern, responsive design with mobile-first approach */

/* ===================================
   CSS CUSTOM PROPERTIES
   =================================== */
:root {
  --primary-color: #1a237e;
  --primary-dark: #0d1444;
  --primary-light: #3949ab;
  --secondary-color: #ff6f00;
  --secondary-dark: #c43e00;
  --secondary-light: #ff9e40;
  --text-dark: #212529;
  --text-light: #6c757d;
  --text-white: #ffffff;
  --bg-light: #f8f9fa;
  --bg-dark: #0a0e27;
  --border-color: #dee2e6;
  --shadow-sm: 0 2px 8px rgba(26, 35, 126, 0.08);
  --shadow-md: 0 4px 16px rgba(26, 35, 126, 0.12);
  --shadow-lg: 0 8px 32px rgba(26, 35, 126, 0.16);
  --transition-base: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: all 0.15s ease-in-out;
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --font-heading: 'Playfair Display', Georgia, serif;
  --border-radius: 4px;
  --spacing-unit: 1rem;
}

/* ===================================
   RESET & BASE STYLES
   =================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

/* ===================================
   TYPOGRAPHY
   =================================== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: calc(var(--spacing-unit) * 1.5);
  color: var(--primary-dark);
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.5rem, 3vw, 2.25rem); }
h4 { font-size: clamp(1.25rem, 2.5vw, 1.75rem); }
h5 { font-size: clamp(1.125rem, 2vw, 1.5rem); }
h6 { font-size: clamp(1rem, 1.5vw, 1.25rem); }

p {
  margin-bottom: var(--spacing-unit);
  color: var(--text-light);
  font-size: clamp(1rem, 1.5vw, 1.125rem);
}

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

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

/* ===================================
   BOOTSTRAP 5 OVERRIDES
   =================================== */

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

.btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
  z-index: -1;
}

.btn:hover::before {
  width: 300px;
  height: 300px;
}

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

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

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

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

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

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

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

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

/* Forms */
.form-control,
.form-select {
  padding: 0.875rem 1.25rem;
  border: 2px solid var(--border-color);
  border-radius: var(--border-radius);
  transition: var(--transition-base);
  font-size: 1rem;
}

.form-control:focus,
.form-select:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.25rem rgba(26, 35, 126, 0.15);
  outline: none;
}

.form-control.is-invalid {
  border-color: #dc3545;
}

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

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

/* Cards */
.card {
  border: none;
  border-radius: calc(var(--border-radius) * 2);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-base);
  overflow: hidden;
}

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

.card-title {
  color: var(--primary-dark);
  font-family: var(--font-heading);
}

.card-text {
  color: var(--text-light);
}

/* Navbar */
.navbar {
  padding: 1rem 0;
  transition: var(--transition-base);
  background-color: var(--text-white);
  box-shadow: var(--shadow-sm);
}

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

.navbar-brand {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--primary-color);
  transition: var(--transition-base);
}

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

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

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

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

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

/* Navbar Toggler */
.navbar-toggler {
  border: 2px solid var(--primary-color);
  padding: 0.5rem 0.75rem;
  transition: var(--transition-base);
}

.navbar-toggler:focus {
  box-shadow: 0 0 0 0.25rem rgba(26, 35, 126, 0.15);
  outline: 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='%231a237e' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ===================================
   HERO SECTION
   =================================== */
.hero-section {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 50%, var(--primary-light) 100%);
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,%3Csvg width="100" height="100" xmlns="http://www.w3.org/2000/svg"%3E%3Cpath d="M0 0h100v100H0z" fill="none"/%3E%3Cpath d="M0 0l100 100M100 0L0 100" stroke="%23ffffff" stroke-width="0.5" opacity="0.1"/%3E%3C/svg%3E');
  opacity: 0.3;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: var(--text-white);
  padding: 2rem;
}

.hero-content h1 {
  color: var(--text-white);
  margin-bottom: 1.5rem;
  animation: fadeInUp 1s ease-out;
}

.hero-content p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.25rem;
  margin-bottom: 2rem;
  animation: fadeInUp 1s ease-out 0.2s both;
}

.hero-content .btn {
  animation: fadeInUp 1s ease-out 0.4s both;
  margin: 0.5rem;
}

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

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

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

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

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

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

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

/* ===================================
   PROJECT GRID
   =================================== */
.project-card {
  position: relative;
  overflow: hidden;
  border-radius: calc(var(--border-radius) * 2);
  margin-bottom: 2rem;
  cursor: pointer;
}

.project-card-image {
  width: 100%;
  height: 400px;
  object-fit: cover;
  transition: var(--transition-base);
}

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

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

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

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

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

.project-card-description {
  color: rgba(255, 255, 255, 0.9);
  transform: translateY(20px);
  transition: var(--transition-base) 0.1s;
}

.project-card:hover .project-card-description {
  transform: translateY(0);
}

.project-card-category {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background-color: var(--secondary-color);
  color: var(--text-white);
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: var(--border-radius);
  margin-bottom: 1rem;
  transform: translateY(20px);
  transition: var(--transition-base) 0.2s;
}

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

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

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

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

.service-item:hover .service-icon {
  background: linear-gradient(135deg, var(--secondary-color) 0%, var(--secondary-light) 100%);
  transform: rotate(360deg);
}

.service-title {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--primary-dark);
}

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

/* ===================================
   TESTIMONIALS
   =================================== */
.testimonial-card {
  background: var(--text-white);
  padding: 2.5rem;
  border-radius: calc(var(--border-radius) * 2);
  box-shadow: var(--shadow-md);
  position: relative;
  margin-bottom: 2rem;
}

.testimonial-card::before {
  content: '"';
  position: absolute;
  top: -20px;
  left: 30px;
  font-size: 6rem;
  color: var(--secondary-color);
  opacity: 0.2;
  font-family: Georgia, serif;
  line-height: 1;
}

.testimonial-text {
  font-size: 1.125rem;
  font-style: italic;
  color: var(--text-dark);
  margin-bottom: 1.5rem;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.testimonial-avatar {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--secondary-color);
}

.testimonial-author-info h5 {
  margin-bottom: 0.25rem;
  color: var(--primary-dark);
}

.testimonial-author-info p {
  margin-bottom: 0;
  font-size: 0.875rem;
  color: var(--text-light);
}

/* ===================================
   CONTACT SECTION
   =================================== */
.contact-info-item {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.contact-icon {
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--secondary-color);
  color: var(--text-white);
  border-radius: 50%;
  font-size: 1.25rem;
  flex-shrink: 0;
}

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

.contact-info-content p,
.contact-info-content a {
  margin-bottom: 0;
  color: var(--text-light);
}

.contact-info-content a:hover {
  color: var(--secondary-color);
}

/* ===================================
   FOOTER
   =================================== */
.footer {
  background-color: var(--bg-dark);
  color: rgba(255, 255, 255, 0.8);
  padding: 4rem 0 2rem;
}

.footer h5 {
  color: var(--text-white);
  margin-bottom: 1.5rem;
  font-family: var(--font-heading);
}

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

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

.footer ul li a {
  color: rgba(255, 255, 255, 0.7);
  transition: var(--transition-base);
}

.footer ul li a:hover {
  color: var(--secondary-color);
  padding-left: 5px;
}

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

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

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

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

/* ===================================
   ANIMATIONS
   =================================== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  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);
  }
}

.fade-in-up {
  animation: fadeInUp 0.8s ease-out;
}

.fade-in {
  animation: fadeIn 0.8s ease-out;
}

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

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

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

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

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

/* ===================================
   LOADING SPINNER
   =================================== */
.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid rgba(26, 35, 126, 0.1);
  border-top-color: var(--primary-color);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* ===================================
   UTILITY CLASSES
   =================================== */
.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);
}

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

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

/* ===================================
   RESPONSIVE DESIGN - MOBILE FIRST
   =================================== */

/* Small devices (landscape phones, 576px and up) */
@media (min-width: 576px) {
  .section {
    padding: 4rem 0;
  }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) {
  .section {
    padding: 5rem 0;
  }
  
  .hero-content h1 {
    margin-bottom: 2rem;
  }
  
  .project-card-image {
    height: 450px;
  }
}

/* Large devices (desktops, 992px and up) */
@media (min-width: 992px) {
  .section {
    padding: 6rem 0;
  }
  
  .navbar-nav .nav-link {
    padding: 0.5rem 1.25rem;
  }
}

/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
  .section {
    padding: 7rem 0;
  }
}

/* Mobile menu styles */
@media (max-width: 991px) {
  .navbar-collapse {
    background-color: var(--text-white);
    padding: 1rem;
    border-radius: var(--border-radius);
    margin-top: 1rem;
    box-shadow: var(--shadow-md);
  }
  
  .navbar-nav .nav-link {
    padding: 0.75rem 1rem;
  }
  
  .navbar-nav .nav-link::after {
    display: none;
  }
  
  .hero-section {
    min-height: 80vh;
  }
  
  .project-card-image {
    height: 300px;
  }
}

/* ===================================
   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-width: 0;
}

*:focus-visible {
  outline: 2px solid var(--secondary-color);
  outline-offset: 2px;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms;
    animation-iteration-count: 1;
    transition-duration: 0.01ms;
    scroll-behavior: auto;
  }
}