/* Slate & Crystal Architecture Studio Theme CSS */

/* ==================== ROOT VARIABLES ==================== */
:root {
  --primary-color: #2C3E50;
  --secondary-color: #E8F4F8;
  --accent-color: #3498db;
  --dark-slate: #1a252f;
  --light-crystal: #f8fcff;
  --text-dark: #2C3E50;
  --text-light: #ffffff;
  --shadow-color: rgba(44, 62, 80, 0.15);
  --transition-speed: 0.4s;
}

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

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  color: var(--text-dark) !important;
  background-color: #ffffff;
  overflow-x: hidden;
  line-height: 1.6;
}

/* ==================== TYPOGRAPHY ==================== */
.display-1 {
  font-weight: 700 !important;
  color: var(--text-light) !important;
  letter-spacing: -1px;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.3);
}

.display-3 {
  font-weight: 600 !important;
  color: var(--primary-color) !important;
}

.display-4 {
  font-weight: 600 !important;
  color: var(--primary-color) !important;
  letter-spacing: -0.5px;
}

.display-5 {
  font-weight: 600 !important;
  color: var(--primary-color) !important;
}

.h3, h3 {
  color: var(--primary-color) !important;
  font-weight: 600 !important;
}

.h4, h4 {
  color: var(--primary-color) !important;
  font-weight: 600 !important;
}

.h5, h5 {
  color: var(--primary-color) !important;
  font-weight: 600 !important;
}

.h6, h6 {
  color: var(--primary-color) !important;
  font-weight: 500 !important;
}

.fs-4 {
  color: var(--text-light) !important;
  opacity: 0.95;
}

.fs-5 {
  color: var(--text-dark) !important;
  line-height: 1.8;
}

.lead {
  color: var(--text-dark) !important;
  opacity: 0.9;
}

.text-muted {
  color: #7f8c8d !important;
}

/* ==================== NAVIGATION ==================== */
.navbar {
  background-color: var(--primary-color) !important;
  padding: 1rem 0;
  transition: all var(--transition-speed) ease;
  box-shadow: 0 2px 15px var(--shadow-color);
  z-index: 1000;
}

.navbar.fixed-top {
  backdrop-filter: blur(10px);
}

.navbar-brand {
  font-size: 1.5rem !important;
  font-weight: 700 !important;
  color: var(--text-light) !important;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: all var(--transition-speed) ease;
}

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

.navbar-dark .navbar-toggler {
  border-color: var(--text-light) !important;
  color: var(--text-light) !important;
}

.navbar-toggler {
  border: 2px solid var(--text-light) !important;
  padding: 0.5rem 0.75rem;
}

.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");
}

.navbar-nav {
  align-items: center;
}

.nav-item {
  margin: 0 0.5rem;
}

.nav-link {
  color: var(--text-light) !important;
  font-weight: 500 !important;
  padding: 0.5rem 1rem !important;
  transition: all var(--transition-speed) ease;
  position: relative;
  text-transform: uppercase;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
}

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

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

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

/* ==================== BUTTONS ==================== */
.btn {
  border-radius: 4px !important;
  font-weight: 600 !important;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all var(--transition-speed) ease;
  border: none !important;
  position: relative;
  overflow: hidden;
}

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

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

.btn-lg {
  background-color: var(--primary-color) !important;
  color: var(--text-light) !important;
  padding: 1rem 2.5rem !important;
  font-size: 1rem !important;
}

.btn-lg:hover {
  background-color: var(--dark-slate) !important;
  color: var(--text-light) !important;
  transform: translateY(-3px);
  box-shadow: 0 8px 20px var(--shadow-color);
}

.btn-sm {
  background-color: var(--primary-color) !important;
  color: var(--text-light) !important;
  padding: 0.5rem 1rem !important;
}

.btn-sm:hover {
  background-color: var(--dark-slate) !important;
  color: var(--text-light) !important;
}

.btn-light {
  background-color: var(--text-light) !important;
  color: var(--primary-color) !important;
  border: 2px solid var(--text-light) !important;
}

.btn-light:hover {
  background-color: var(--secondary-color) !important;
  color: var(--primary-color) !important;
  border-color: var(--secondary-color) !important;
}

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

.btn-outline-secondary:hover,
.btn-outline-secondary.active {
  background-color: var(--primary-color) !important;
  color: var(--text-light) !important;
  border-color: var(--primary-color) !important;
}

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

.btn-outline-dark:hover {
  background-color: var(--primary-color) !important;
  color: var(--text-light) !important;
}

.filter-btn {
  margin: 0.5rem;
  padding: 0.75rem 1.5rem !important;
}

/* ==================== HERO SECTION ==================== */
.position-relative {
  min-height: 100vh;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--dark-slate) 100%);
  position: relative;
}

.position-relative::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('data:image/svg+xml,%3Csvg width="60" height="60" viewBox="0 0 60 60" xmlns="http://www.w3.org/2000/svg"%3E%3Cg fill="none" fill-rule="evenodd"%3E%3Cg fill="%23ffffff" fill-opacity="0.05"%3E%3Cpath d="M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z"/%3E%3C/g%3E%3C/g%3E%3C/svg%3E');
  opacity: 0.3;
}

.position-absolute.w-100.h-100 {
  z-index: 1;
}

.position-relative .d-flex {
  z-index: 2;
}

/* ==================== SECTIONS ==================== */
.py-5 {
  padding: 4rem 0 !important;
}

.my-5 {
  margin: 4rem 0 !important;
}

.bg-white {
  background-color: #ffffff !important;
}

section {
  position: relative;
}

/* ==================== IMAGES ==================== */
.img-fluid {
  border-radius: 8px;
  transition: all var(--transition-speed) ease;
}

.img-fluid:hover {
  transform: scale(1.02);
}

.shadow-lg {
  box-shadow: 0 15px 40px var(--shadow-color) !important;
}

.shadow {
  box-shadow: 0 5px 20px var(--shadow-color) !important;
}

.shadow-sm {
  box-shadow: 0 2px 10px var(--shadow-color) !important;
}

/* ==================== PORTFOLIO ==================== */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.portfolio-item {
  opacity: 0;
  animation: fadeInUp 0.6s ease forwards;
}

.portfolio-item:nth-child(1) { animation-delay: 0.1s; }
.portfolio-item:nth-child(2) { animation-delay: 0.2s; }
.portfolio-item:nth-child(3) { animation-delay: 0.3s; }
.portfolio-item:nth-child(4) { animation-delay: 0.4s; }
.portfolio-item:nth-child(5) { animation-delay: 0.5s; }
.portfolio-item:nth-child(6) { animation-delay: 0.6s; }

.portfolio-card {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  cursor: pointer;
  transition: all var(--transition-speed) ease;
  background-color: var(--secondary-color);
}

.portfolio-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px var(--shadow-color);
}

.portfolio-img {
  width: 100%;
  height: 350px;
  object-fit: cover;
  transition: all var(--transition-speed) ease;
}

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

.portfolio-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(44, 62, 80, 0.95), transparent);
  padding: 2rem;
  transform: translateY(60%);
  transition: all var(--transition-speed) ease;
}

.portfolio-card:hover .portfolio-overlay {
  transform: translateY(0);
}

.portfolio-overlay h4,
.portfolio-overlay .h4 {
  color: var(--text-light) !important;
  margin-bottom: 0.5rem;
}

.portfolio-overlay p {
  color: var(--text-light) !important;
  opacity: 0.9;
  margin-bottom: 0;
}

/* ==================== CARDS ==================== */
.card {
  border: none !important;
  border-radius: 8px !important;
  transition: all var(--transition-speed) ease;
  background-color: #ffffff !important;
  overflow: hidden;
}

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

.card.border-0 {
  background-color: var(--light-crystal) !important;
}

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

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

.card-body {
  padding: 1.5rem !important;
}

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

.card-text {
  color: var(--text-dark) !important;
  line-height: 1.6;
}

/* ==================== BADGES ==================== */
.badge {
  background-color: var(--primary-color) !important;
  color: var(--text-light) !important;
  padding: 0.5rem 1rem !important;
  font-weight: 500 !important;
  border-radius: 4px !important;
  font-size: 0.85rem !important;
}

/* ==================== FORMS ==================== */
.form-label {
  color: var(--primary-color) !important;
  font-weight: 600 !important;
  margin-bottom: 0.5rem;
}

.form-control,
.form-select {
  border: 2px solid var(--secondary-color) !important;
  border-radius: 4px !important;
  padding: 0.75rem 1rem !important;
  transition: all var(--transition-speed) ease;
  background-color: #ffffff !important;
  color: var(--text-dark) !important;
}

.form-control:focus,
.form-select:focus {
  border-color: var(--primary-color) !important;
  box-shadow: 0 0 0 0.2rem rgba(44, 62, 80, 0.15) !important;
  background-color: #ffffff !important;
}

.form-control::placeholder {
  color: #95a5a6 !important;
}

.form-check-input {
  border: 2px solid var(--primary-color) !important;
  width: 1.25rem;
  height: 1.25rem;
}

.form-check-input:checked {
  background-color: var(--primary-color) !important;
  border-color: var(--primary-color) !important;
}

.form-check-label {
  color: var(--text-dark) !important;
  margin-left: 0.5rem;
}

/* ==================== ICONS ==================== */
.bi {
  vertical-align: middle;
  transition: all var(--transition-speed) ease;
}

.bi-send,
.bi-geo-alt-fill,
.bi-telephone-fill,
.bi-envelope-fill,
.bi-train-front,
.bi-p-square,
.bi-bicycle,
.bi-telephone,
.bi-geo-alt,
.bi-envelope,
.bi-rulers,
.bi-calendar-check,
.bi-award,
.bi-house-heart,
.bi-check-circle-fill,
.bi-building,
.bi-tree,
.bi-bank,
.bi-map {
  color: var(--primary-color) !important;
  font-size: 1.5rem;
}

.fs-1 .bi {
  font-size: 3rem !important;
  color: var(--primary-color) !important;
}

/* ==================== LISTS ==================== */
.list-unstyled {
  padding-left: 0;
  list-style: none;
}

.list-unstyled li {
  padding: 0.5rem 0;
  color: var(--text-dark) !important;
}

.list-unstyled a {
  color: var(--text-dark) !important;
  text-decoration: none !important;
  transition: all var(--transition-speed) ease;
}

.list-unstyled a:hover {
  color: var(--primary-color) !important;
  padding-left: 5px;
}

/* ==================== TEXT UTILITIES ==================== */
.text-white {
  color: var(--text-light) !important;
}

.text-decoration-none {
  text-decoration: none !important;
}

.text-decoration-none:hover {
  color: var(--primary-color) !important;
}

.fw-bold {
  font-weight: 700 !important;
}

.opacity-75 {
  opacity: 0.75 !important;
}

.opacity-25 {
  opacity: 0.25 !important;
}

/* ==================== SPACING UTILITIES ==================== */
.p-5 {
  padding: 3rem !important;
}

.p-4 {
  padding: 2rem !important;
}

.p-3 {
  padding: 1rem !important;
}

.px-5 {
  padding-left: 3rem !important;
  padding-right: 3rem !important;
}

.px-4 {
  padding-left: 2rem !important;
  padding-right: 2rem !important;
}

.px-3 {
  padding-left: 1rem !important;
  padding-right: 1rem !important;
}

.py-5 {
  padding-top: 4rem !important;
  padding-bottom: 4rem !important;
}

.py-3 {
  padding-top: 1rem !important;
  padding-bottom: 1rem !important;
}

.py-2 {
  padding-top: 0.5rem !important;
  padding-bottom: 0.5rem !important;
}

.mt-5 {
  margin-top: 3rem !important;
}

.mt-4 {
  margin-top: 2rem !important;
}

.mt-3 {
  margin-top: 1rem !important;
}

.mt-2 {
  margin-top: 0.5rem !important;
}

.mb-5 {
  margin-bottom: 3rem !important;
}

.mb-4 {
  margin-bottom: 2rem !important;
}

.mb-3 {
  margin-bottom: 1rem !important;
}

.mb-2 {
  margin-bottom: 0.5rem !important;
}

.mb-0 {
  margin-bottom: 0 !important;
}

/* ==================== MODAL ==================== */
.modal {
  z-index: 1060;
}

.modal-content {
  border: none !important;
  border-radius: 8px !important;
  overflow: hidden;
  background-color: #ffffff !important;
}

.modal-header {
  background-color: var(--primary-color) !important;
  color: var(--text-light) !important;
  border-bottom: none !important;
  padding: 1.5rem !important;
}

.modal-title {
  color: var(--text-light) !important;
  font-weight: 600 !important;
}

.modal-body {
  padding: 2rem !important;
  color: var(--text-dark) !important;
}

.btn-close,
.btn-close-white {
  filter: brightness(0) invert(1);
  opacity: 1 !important;
}

.btn-close:hover,
.btn-close-white:hover {
  opacity: 0.8 !important;
}

/* ==================== FOOTER ==================== */
footer {
  background-color: var(--primary-color) !important;
  color: var(--text-light) !important;
  padding: 3rem 0 1rem;
}

footer h5,
footer h6,
footer .h5,
footer .h6 {
  color: var(--text-light) !important;
}

footer p {
  color: var(--text-light) !important;
  opacity: 0.9;
}

footer a {
  color: var(--text-light) !important;
  text-decoration: none;
  transition: all var(--transition-speed) ease;
}

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

footer .bi {
  color: var(--text-light) !important;
}

/* ==================== 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 {
  animation: fadeIn 0.6s ease;
}

/* ==================== SCROLL ANIMATIONS ==================== */
.scroll-animate {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease;
}

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

/* ==================== STICKY ELEMENTS ==================== */
.sticky-lg-top {
  position: sticky;
  top: 100px;
  z-index: 10;
}

/* ==================== OVERFLOW ==================== */
.overflow-hidden {
  overflow: hidden !important;
}

/* ==================== ROUNDED UTILITIES ==================== */
.rounded {
  border-radius: 8px !important;
}

.rounded-circle {
  border-radius: 50% !important;
}

/* ==================== RESPONSIVE DESIGN ==================== */

/* Tablets */
@media (max-width: 991px) {
  .display-1 {
    font-size: 3rem !important;
  }
  
  .display-3 {
    font-size: 2.5rem !important;
  }
  
  .display-4 {
    font-size: 2rem !important;
  }
  
  .display-5 {
    font-size: 1.75rem !important;
  }
  
  .navbar-collapse {
    background-color: var(--primary-color);
    padding: 1rem;
    margin-top: 1rem;
    border-radius: 8px;
  }
  
  .nav-item {
    margin: 0.5rem 0;
  }
  
  .portfolio-grid {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
  }
  
  .btn-lg {
    padding: 0.875rem 2rem !important;
    font-size: 0.95rem !important;
  }
  
  .px-5 {
    padding-left: 2rem !important;
    padding-right: 2rem !important;
  }
  
  .py-5 {
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
  }
}

/* Mobile */
@media (max-width: 767px) {
  .display-1 {
    font-size: 2.5rem !important;
  }
  
  .display-3 {
    font-size: 2rem !important;
  }
  
  .display-4 {
    font-size: 1.75rem !important;
  }
  
  .display-5 {
    font-size: 1.5rem !important;
  }
  
  .h3, h3 {
    font-size: 1.5rem !important;
  }
  
  .h4, h4 {
    font-size: 1.25rem !important;
  }
  
  .position-relative {
    min-height: 100vh;
  }
  
  .portfolio-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .portfolio-img {
    height: 250px;
  }
  
  .btn-lg {
    padding: 0.75rem 1.5rem !important;
    font-size: 0.9rem !important;
    width: 100%;
    margin-bottom: 1rem;
  }
  
  .px-4 {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  
  .py-5 {
    padding-top: 2rem !important;
    padding-bottom: 2rem !important;
  }
  
  .p-5 {
    padding: 2rem !important;
  }
  
  .card-img-top {
    height: 200px;
  }
  
  .modal-dialog {
    margin: 1rem !important;
  }
  
  .flex-column {
    flex-direction: column !important;
  }
  
  .text-md-start,
  .text-md-end {
    text-align: center !important;
  }
  
  .mt-lg-0 {
    margin-top: 1rem !important;
  }
  
  .d-none.d-md-inline {
    display: none !important;
  }
  
  .gap-3 {
    gap: 0.5rem !important;
  }
}

/* Small Mobile */
@media (max-width: 575px) {
  .display-1 {
    font-size: 2rem !important;
  }
  
  .fs-4 {
    font-size: 1rem !important;
  }
  
  .container-fluid {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  
  .px-3 {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }
  
  .filter-btn {
    padding: 0.5rem 1rem !important;
    font-size: 0.85rem !important;
    margin: 0.25rem;
  }
}

/* ==================== PRINT STYLES ==================== */
@media print {
  .navbar,
  .btn,
  footer {
    display: none !important;
  }
  
  body {
    color: #000 !important;
    background: #fff !important;
  }
}

/* ==================== ACCESSIBILITY ==================== */
.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* Focus visible for keyboard navigation */
a:focus-visible,
button:focus-visible,
.btn:focus-visible,
.form-control:focus-visible,
.form-select:focus-visible {
  outline: 3px solid var(--accent-color) !important;
  outline-offset: 2px !important;
}

/* ==================== UTILITY CLASSES ==================== */
.d-block {
  display: block !important;
}

.d-inline-block {
  display: inline-block !important;
}

.d-flex {
  display: flex !important;
}

.flex-column {
  flex-direction: column !important;
}

.flex-row-reverse {
  flex-direction: row-reverse !important;
}

.align-items-center {
  align-items: center !important;
}

.align-items-start {
  align-items: flex-start !important;
}

.justify-content-center {
  justify-content: center !important;
}

.justify-content-end {
  justify-content: flex-end !important;
}

.justify-content-between {
  justify-content: space-between !important;
}

.text-center {
  text-align: center !important;
}

.text-end {
  text-align: right !important;
}

.w-100 {
  width: 100% !important;
}

.h-100 {
  height: 100% !important;
}

.mx-auto {
  margin-left: auto !important;
  margin-right: auto !important;
}

.ms-auto {
  margin-left: auto !important;
}

.me-2 {
  margin-right: 0.5rem !important;
}

.me-3 {
  margin-right: 1rem !important;
}

.g-0 {
  gap: 0 !important;
}

.g-3 {
  gap: 1rem !important;
}

.g-4 {
  gap: 1.5rem !important;
}

.g-5 {
  gap: 3rem !important;
}

/* ==================== LOADING ANIMATION ==================== */
.loading {
  position: relative;
  pointer-events: none;
  opacity: 0.6;
}

.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 30px;
  height: 30px;
  margin: -15px 0 0 -15px;
  border: 3px solid var(--secondary-color);
  border-top-color: var(--primary-color);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* ==================== CUSTOM SCROLLBAR ==================== */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--secondary-color);
}

::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--dark-slate);
}

/* ==================== SELECTION ==================== */
::selection {
  background-color: var(--primary-color);
  color: var(--text-light);
}

::-moz-selection {
  background-color: var(--primary-color);
  color: var(--text-light);
}