/* Arctic Forest Architecture Studio - Custom Styles */

/* ===========================
   ROOT VARIABLES & RESETS
   =========================== */
:root {
  --primary-color: #2C5F41;
  --secondary-color: #E8F4F8;
  --accent-forest: #1a4029;
  --accent-ice: #d4eef8;
  --text-dark: #1a2b23;
  --text-light: #ffffff;
  --transition-speed: 0.4s;
  --shadow-soft: 0 4px 20px rgba(44, 95, 65, 0.15);
  --shadow-hover: 0 8px 30px rgba(44, 95, 65, 0.25);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

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

/* ===========================
   TYPOGRAPHY
   =========================== */
.display-2, .display-3, .display-4, .display-5, .display-6 {
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-dark) !important;
}

.text-white.display-2,
.text-white.display-3,
.text-white.display-4,
.text-white.display-5 {
  color: var(--text-light) !important;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.3);
}

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

.h3, .h4, .h5, h3, h4, h5 {
  font-weight: 600;
  color: var(--text-dark) !important;
}

.fs-4, .fs-5 {
  color: inherit;
}

.text-white.fs-4,
.text-white.fs-5,
.text-white .lead {
  color: var(--text-light) !important;
}

.text-muted {
  color: #6c757d !important;
}

/* ===========================
   NAVIGATION
   =========================== */
.navbar {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-forest) 100%) !important;
  padding: 1rem 0;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
  transition: all var(--transition-speed) ease;
  backdrop-filter: blur(10px);
}

.navbar.scrolled {
  padding: 0.5rem 0;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

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

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

.navbar-dark .navbar-nav .nav-link {
  color: rgba(255, 255, 255, 0.9) !important;
  font-weight: 500 !important;
  padding: 0.5rem 1.2rem !important;
  margin: 0 0.2rem;
  border-radius: 6px;
  transition: all var(--transition-speed) ease;
  position: relative;
}

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

.navbar-dark .navbar-nav .nav-link:hover,
.navbar-dark .navbar-nav .nav-link.active {
  color: var(--text-light) !important;
  background: rgba(255, 255, 255, 0.1) !important;
}

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

.navbar-toggler {
  border: 2px solid rgba(255, 255, 255, 0.8) !important;
  padding: 0.5rem 0.75rem;
}

.navbar-toggler:focus {
  box-shadow: 0 0 0 0.2rem rgba(255, 255, 255, 0.3) !important;
}

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

/* ===========================
   BUTTONS
   =========================== */
.btn {
  font-weight: 600 !important;
  border-radius: 8px !important;
  transition: all var(--transition-speed) ease !important;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-width: 2px !important;
}

.btn-lg {
  padding: 0.875rem 2rem !important;
  font-size: 1rem !important;
}

.btn-outline-light {
  color: var(--text-light) !important;
  border-color: var(--text-light) !important;
  background: transparent !important;
}

.btn-outline-light:hover {
  background: var(--text-light) !important;
  color: var(--primary-color) !important;
  border-color: var(--text-light) !important;
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(255, 255, 255, 0.3);
}

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

.btn-light:hover {
  background: var(--secondary-color) !important;
  color: var(--primary-color) !important;
  border-color: var(--secondary-color) !important;
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

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

.btn-outline-success:hover,
.btn-outline-success.active {
  background: var(--primary-color) !important;
  color: var(--text-light) !important;
  border-color: var(--primary-color) !important;
  transform: translateY(-2px);
  box-shadow: var(--shadow-soft);
}

.btn-sm {
  padding: 0.4rem 1rem !important;
  font-size: 0.875rem !important;
}

.btn:focus {
  box-shadow: 0 0 0 0.2rem rgba(44, 95, 65, 0.3) !important;
}

/* ===========================
   HERO SECTION
   =========================== */
.position-relative.overflow-hidden {
  min-height: 100vh;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-forest) 100%);
  position: relative;
  overflow: hidden !important;
}

.position-relative.overflow-hidden::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    repeating-linear-gradient(45deg, transparent, transparent 35px, rgba(255,255,255,.03) 35px, rgba(255,255,255,.03) 70px);
  animation: snowfall 20s linear infinite;
}

.position-relative.overflow-hidden::after {
  content: '';
  position: absolute;
  bottom: -50px;
  left: -50px;
  right: -50px;
  height: 200px;
  background: rgba(232, 244, 248, 0.1);
  border-radius: 50%;
  filter: blur(40px);
}

@keyframes snowfall {
  0% { transform: translateY(-100px); }
  100% { transform: translateY(100px); }
}

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

.position-relative .container {
  position: relative;
  z-index: 2;
}

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

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

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

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

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

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

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

.shadow-sm {
  box-shadow: var(--shadow-soft) !important;
}

.shadow,
.shadow-lg {
  box-shadow: var(--shadow-hover) !important;
}

/* ===========================
   BOOTSTRAP ICONS
   =========================== */
.bi {
  font-size: 2rem;
  color: var(--primary-color) !important;
}

.bi-telephone-fill,
.bi-envelope-fill,
.bi-geo-alt-fill,
.bi-telephone,
.bi-envelope,
.bi-geo-alt,
.bi-check-circle-fill,
.bi-airplane-fill,
.bi-camera-video-fill,
.bi-people-fill,
.bi-tree,
.bi-snow,
.bi-house-heart,
.bi-building,
.bi-clock-history,
.bi-globe {
  transition: all var(--transition-speed) ease;
}

.card:hover .bi {
  transform: scale(1.1);
  color: var(--accent-forest) !important;
}

.rounded-circle {
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--secondary-color) !important;
}

.rounded-circle .bi {
  font-size: 1.5rem !important;
}

/* ===========================
   BACKGROUNDS
   =========================== */
.bg-light {
  background-color: var(--secondary-color) !important;
}

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

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

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

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

.portfolio-item {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: var(--shadow-soft);
  transition: all var(--transition-speed) ease;
  cursor: pointer;
}

.portfolio-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to bottom, transparent 0%, rgba(44, 95, 65, 0.9) 100%);
  opacity: 0;
  transition: opacity var(--transition-speed) ease;
  z-index: 1;
}

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

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

.portfolio-item img {
  width: 100%;
  height: 350px;
  transition: transform var(--transition-speed) ease;
}

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

.object-fit-cover {
  object-fit: cover !important;
}

/* ===========================
   FILTER BUTTONS
   =========================== */
.filter-btn {
  margin: 0.5rem;
  padding: 0.5rem 1.5rem !important;
  font-size: 0.95rem !important;
}

.filter-btn.active {
  background: var(--primary-color) !important;
  color: var(--text-light) !important;
  border-color: var(--primary-color) !important;
}

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

/* ===========================
   FORMS
   =========================== */
.form-control,
.form-control-lg,
.form-select,
.form-select-lg {
  border: 2px solid #dee2e6 !important;
  border-radius: 8px !important;
  padding: 0.875rem 1.25rem !important;
  transition: all var(--transition-speed) ease !important;
  background: white !important;
  color: var(--text-dark) !important;
}

.form-control:focus,
.form-control-lg:focus,
.form-select:focus,
.form-select-lg:focus {
  border-color: var(--primary-color) !important;
  box-shadow: 0 0 0 0.2rem rgba(44, 95, 65, 0.15) !important;
  background: white !important;
}

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

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

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

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

/* ===========================
   MODAL
   =========================== */
.modal-content {
  border: none !important;
  border-radius: 12px !important;
  overflow: hidden;
}

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

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

.modal-body {
  padding: 2rem !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: var(--primary-color) !important;
  color: var(--text-light) !important;
}

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

footer a:hover {
  color: var(--secondary-color) !important;
  opacity: 1;
  transform: translateX(3px);
}

footer .bi-linkedin,
footer .bi-instagram,
footer .bi-facebook {
  font-size: 1.5rem;
  color: var(--text-light) !important;
  transition: all var(--transition-speed) ease;
}

footer .bi-linkedin:hover,
footer .bi-instagram:hover,
footer .bi-facebook:hover {
  color: var(--secondary-color) !important;
  transform: translateY(-3px);
}

.border-top {
  border-top: 1px solid rgba(255, 255, 255, 0.2) !important;
}

/* ===========================
   UTILITIES
   =========================== */
.opacity-75 {
  opacity: 0.75 !important;
}

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

.list-unstyled {
  list-style: none !important;
  padding-left: 0 !important;
}

.rounded {
  border-radius: 12px !important;
}

.img-fluid {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

.sticky-top,
.sticky-lg-top {
  position: sticky !important;
  top: 80px !important;
  z-index: 100;
}

.position-sticky {
  position: sticky !important;
  top: 100px !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 scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

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

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

.animate-scale-in {
  animation: scaleIn 0.6s ease forwards;
}

/* Stagger animation delays */
.animate-delay-1 { animation-delay: 0.1s; }
.animate-delay-2 { animation-delay: 0.2s; }
.animate-delay-3 { animation-delay: 0.3s; }
.animate-delay-4 { animation-delay: 0.4s; }
.animate-delay-5 { animation-delay: 0.5s; }

/* ===========================
   RESPONSIVE DESIGN
   =========================== */
@media (max-width: 991.98px) {
  .navbar-collapse {
    background: rgba(26, 64, 41, 0.95);
    padding: 1.5rem;
    border-radius: 8px;
    margin-top: 1rem;
    backdrop-filter: blur(10px);
  }
  
  .navbar-nav {
    gap: 0.5rem;
  }
  
  .display-2 {
    font-size: 2.5rem !important;
  }
  
  .display-3 {
    font-size: 2.2rem !important;
  }
  
  .display-4 {
    font-size: 2rem !important;
  }
  
  .display-5 {
    font-size: 1.8rem !important;
  }
  
  .btn-lg {
    padding: 0.75rem 1.5rem !important;
    font-size: 0.95rem !important;
  }
  
  .portfolio-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .card-body {
    padding: 1.5rem !important;
  }
  
  .py-5 {
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
  }
}

@media (max-width: 767.98px) {
  .display-2 {
    font-size: 2rem !important;
  }
  
  .display-3 {
    font-size: 1.8rem !important;
  }
  
  .fs-4 {
    font-size: 1.1rem !important;
  }
  
  .fs-5 {
    font-size: 1rem !important;
  }
  
  .btn-lg.px-5 {
    padding-left: 2rem !important;
    padding-right: 2rem !important;
  }
  
  .position-relative.overflow-hidden {
    min-height: 100vh;
  }
  
  .modal-dialog {
    margin: 1rem !important;
  }
  
  .modal-body {
    padding: 1.5rem !important;
  }
}

@media (max-width: 575.98px) {
  .container-fluid.px-4 {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  
  .display-2 {
    font-size: 1.75rem !important;
  }
  
  .navbar-brand {
    font-size: 1.25rem !important;
  }
  
  .btn-lg {
    width: 100%;
    margin-bottom: 0.5rem;
  }
  
  .gap-3 {
    gap: 0.5rem !important;
  }
  
  .p-5 {
    padding: 2rem !important;
  }
  
  .p-4 {
    padding: 1.5rem !important;
  }
}

/* ===========================
   ACCESSIBILITY
   =========================== */
:focus-visible {
  outline: 3px solid var(--primary-color);
  outline-offset: 3px;
}

.btn:focus-visible {
  outline: 3px solid var(--primary-color);
  outline-offset: 3px;
}

a:focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
  border-radius: 4px;
}

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

.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 30px;
  height: 30px;
  border: 3px solid rgba(44, 95, 65, 0.3);
  border-top-color: var(--primary-color);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: translate(-50%, -50%) rotate(360deg); }
}

/* ===========================
   SCROLL TO TOP BUTTON
   =========================== */
#scrollTopBtn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--primary-color) !important;
  color: var(--text-light) !important;
  border: none;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 1000;
  box-shadow: var(--shadow-hover);
  transition: all var(--transition-speed) ease;
}

#scrollTopBtn:hover {
  background: var(--accent-forest) !important;
  transform: translateY(-5px);
}

#scrollTopBtn.show {
  display: flex;
}

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

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

::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 6px;
  border: 2px solid var(--secondary-color);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-forest);
}

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

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