/**
 * Non-Critical CSS for Arron Bennett Building Contractors
 * This file is loaded asynchronously after initial page render
 * to avoid blocking First Contentful Paint (FCP)
 */

/* ============================================================
   ENHANCED TYPOGRAPHY - Complete font stack
   ============================================================ */

/* Extended heading styles for all sizes */
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

@media (min-width: 768px) {
  h4 { font-size: 1.875rem; }
  h5 { font-size: 1.5rem; }
  h6 { font-size: 1.25rem; }
}

/* Paragraph and text styles */
p {
  margin-top: 1rem;
  margin-bottom: 1rem;
  line-height: 1.75;
}

/* Link styles */
a {
  color: #F27A5E;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  transition: all 0.2s ease;
}

a:hover {
  color: #e05a3f;
  text-decoration-thickness: 2px;
}

/* List styles */
ul, ol {
  margin: 1rem 0;
  padding-left: 2rem;
}

li {
  margin: 0.5rem 0;
}

/* Blockquote styles */
blockquote {
  margin: 2rem 0;
  padding-left: 1.5rem;
  border-left: 4px solid #F27A5E;
  font-style: italic;
  color: #4B5563;
}

/* ============================================================
   FORM STYLES - Complete form elements
   ============================================================ */

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="url"],
input[type="password"],
input[type="number"],
input[type="search"],
textarea,
select {
  width: 100%;
  padding: 0.75rem 1rem;
  margin: 0.5rem 0;
  border: 2px solid #D1D5DB;
  border-radius: 6px;
  font-size: 1rem;
  transition: all 0.2s ease;
  font-family: inherit;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: #F27A5E;
  box-shadow: 0 0 0 3px rgba(242, 122, 94, 0.1);
}

label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: #374151;
}

/* ============================================================
   BUTTON VARIANTS - Complete button system
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.5;
  text-decoration: none;
  border-radius: 6px;
  border: 2px solid transparent;
  transition: all 0.3s ease;
  cursor: pointer;
  white-space: nowrap;
}

.btn-primary {
  color: white;
  background-color: #F27A5E;
  border-color: #F27A5E;
}

.btn-primary:hover {
  background-color: #e05a3f;
  border-color: #e05a3f;
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(242, 122, 94, 0.3);
}

.btn-secondary {
  color: white;
  background-color: #021f59;
  border-color: #021f59;
}

.btn-secondary:hover {
  background-color: #01173d;
  border-color: #01173d;
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(2, 31, 89, 0.3);
}

.btn-outline {
  color: #021f59;
  background-color: transparent;
  border-color: #021f59;
}

.btn-outline:hover {
  color: white;
  background-color: #021f59;
  border-color: #021f59;
}

/* ============================================================
   CARD STYLES - Service and project cards
   ============================================================ */

.card {
  background: white;
  border-radius: 12px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: all 0.3s ease;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.card-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
}

.card-body {
  padding: 1.5rem;
}

.card-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: #021f59;
}

.card-text {
  color: #4B5563;
  line-height: 1.6;
}

/* ============================================================
   GRID LAYOUTS - Responsive grid system
   ============================================================ */

.grid {
  display: grid;
  gap: 2rem;
}

.grid-cols-1 {
  grid-template-columns: repeat(1, minmax(0, 1fr));
}

@media (min-width: 640px) {
  .sm\:grid-cols-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 768px) {
  .md\:grid-cols-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .lg\:grid-cols-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

/* ============================================================
   TESTIMONIAL STYLES - Testimonial cards and carousel
   ============================================================ */

.testimonial {
  background: #F9FAFB;
  padding: 2rem;
  border-radius: 12px;
  position: relative;
}

.testimonial::before {
  content: '"';
  position: absolute;
  top: -10px;
  left: 20px;
  font-size: 4rem;
  color: #F27A5E;
  opacity: 0.3;
  font-family: Georgia, serif;
}

.testimonial-content {
  font-style: italic;
  color: #4B5563;
  margin-bottom: 1.5rem;
  line-height: 1.8;
}

.testimonial-author {
  font-weight: 700;
  color: #021f59;
  margin-bottom: 0.25rem;
}

.testimonial-location {
  color: #6B7280;
  font-size: 0.875rem;
}

.testimonial-rating {
  display: flex;
  gap: 0.25rem;
  margin-top: 0.75rem;
}

.star {
  width: 20px;
  height: 20px;
  color: #FBB040;
}

/* ============================================================
   ANIMATION UTILITIES - Scroll animations and transitions
   ============================================================ */

.fade-in-up {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease-out;
}

.fade-in-up.visible {
  opacity: 1;
  transform: translateY(0);
}

.scale-on-hover {
  transition: transform 0.3s ease;
}

.scale-on-hover:hover {
  transform: scale(1.05);
}

.slide-in-left {
  transform: translateX(-100px);
  opacity: 0;
  transition: all 0.8s ease-out;
}

.slide-in-left.visible {
  transform: translateX(0);
  opacity: 1;
}

.slide-in-right {
  transform: translateX(100px);
  opacity: 0;
  transition: all 0.8s ease-out;
}

.slide-in-right.visible {
  transform: translateX(0);
  opacity: 1;
}

/* ============================================================
   OVERLAY STYLES - Image overlays and gradients
   ============================================================ */

.overlay {
  position: relative;
  overflow: hidden;
}

.overlay::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    180deg,
    rgba(2, 31, 89, 0.4) 0%,
    rgba(2, 31, 89, 0.7) 100%
  );
  z-index: 1;
}

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

/* ============================================================
   BREADCRUMB STYLES - Navigation breadcrumbs
   ============================================================ */

.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 0;
  font-size: 0.875rem;
}

.breadcrumb-item {
  color: #6B7280;
  text-decoration: none;
  transition: color 0.2s ease;
}

.breadcrumb-item:hover {
  color: #F27A5E;
}

.breadcrumb-separator {
  color: #9CA3AF;
}

.breadcrumb-current {
  color: #021f59;
  font-weight: 600;
}

/* ============================================================
   BADGE STYLES - Status badges and tags
   ============================================================ */

.badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-primary {
  background-color: #FEF3F2;
  color: #F27A5E;
}

.badge-secondary {
  background-color: #EFF6FF;
  color: #021f59;
}

.badge-success {
  background-color: #F0FDF4;
  color: #16A34A;
}

/* ============================================================
   TABLE STYLES - Data tables
   ============================================================ */

.table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
}

.table th,
.table td {
  padding: 0.75rem;
  text-align: left;
  border-bottom: 1px solid #E5E7EB;
}

.table th {
  background-color: #F9FAFB;
  font-weight: 700;
  color: #374151;
  text-transform: uppercase;
  font-size: 0.875rem;
  letter-spacing: 0.05em;
}

.table tbody tr:hover {
  background-color: #F9FAFB;
}

/* ============================================================
   RESPONSIVE UTILITIES - Visibility and spacing
   ============================================================ */

.hide-mobile {
  display: none;
}

@media (min-width: 768px) {
  .hide-mobile {
    display: block;
  }
  .hide-desktop {
    display: none;
  }
}

.spacing-xs { margin: 0.5rem; }
.spacing-sm { margin: 1rem; }
.spacing-md { margin: 2rem; }
.spacing-lg { margin: 3rem; }
.spacing-xl { margin: 4rem; }

/* ============================================================
   PRINT STYLES - Print-friendly styles
   ============================================================ */

@media print {
  .no-print {
    display: none !important;
  }

  body {
    font-size: 12pt;
    line-height: 1.5;
  }

  a {
    text-decoration: underline;
  }

  .page-header,
  .mobile-menu,
  .footer {
    display: none;
  }
}