@import "slick-carousel/slick/slick.css";
@import "slick-carousel/slick/slick-theme.css";
@import "tailwindcss";

@theme {
  --animate-marquee: marquee 25s linear infinite;
  --color-custom-1: #16a34a;
  --color-custom-2: #f5f5f5;
  --color-custom-3: #111111;
  --color-custom-4: #13371f;

  /* Additional color variations */
  --color-custom-1-light: #22c55e;
  --color-custom-1-lighter: #dcfce7;
  --color-custom-2-dark: #e5e5e5;
  --color-custom-3-light: #374151;
  --color-custom-3-lighter: #6b7280;
  --color-custom-3-lightest: #9ca3af;

  /* Category colors using custom palette variations */
  --color-category-residential: #16a34a;
  --color-category-residential-bg: #dcfce7;
  --color-category-commercial: #13371f;
  --color-category-commercial-bg: #f0fdf4;
  --color-category-healthcare: #16a34a;
  --color-category-healthcare-bg: #dcfce7;
  --color-category-automotive: #13371f;
  --color-category-automotive-bg: #f0fdf4;
  --color-category-hospitality: #16a34a;
  --color-category-hospitality-bg: #dcfce7;
  --color-category-other: #374151;
  --color-category-other-bg: #f5f5f5;

  /* Rating/Star colors */
  --color-rating: #fbbf24;
  --color-rating-inactive: #d1d5db;

  /* Social media colors */
  --color-facebook: #1877f2;
  --color-facebook-bg: #dbeafe;
  --color-twitter: #1da1f2;
  --color-twitter-bg: #dbeafe;
  --color-linkedin: #0a66c2;
  --color-linkedin-bg: #dbeafe;
  --color-email: #6b7280;
  --color-email-bg: #f5f5f5;
}

@layer base {
  @font-face {
    font-family: "Montserrat";
    src:
      url("/fonts/Montserrat-Thin.woff2") format("woff2"),
      url("/fonts/Montserrat-Thin.woff") format("woff");
    font-weight: 100;
    font-style: normal;
    font-display: swap;
  }

  @font-face {
    font-family: "Montserrat";
    src:
      url("/fonts/Montserrat-ExtraLight.woff2") format("woff2"),
      url("/fonts/Montserrat-ExtraLight.woff") format("woff");
    font-weight: 200;
    font-style: normal;
    font-display: swap;
  }

  @font-face {
    font-family: "Montserrat";
    src:
      url("/fonts/Montserrat-Light.woff2") format("woff2"),
      url("/fonts/Montserrat-Light.woff") format("woff");
    font-weight: 300;
    font-style: normal;
    font-display: swap;
  }

  @font-face {
    font-family: "Montserrat";
    src:
      url("/fonts/Montserrat-Regular.woff2") format("woff2"),
      url("/fonts/Montserrat-Regular.woff") format("woff");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
  }

  @font-face {
    font-family: "Montserrat";
    src:
      url("/fonts/Montserrat-Medium.woff2") format("woff2"),
      url("/fonts/Montserrat-Medium.woff") format("woff");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
  }

  @font-face {
    font-family: "Montserrat";
    src:
      url("/fonts/Montserrat-SemiBold.woff2") format("woff2"),
      url("/fonts/Montserrat-SemiBold.woff") format("woff");
    font-weight: 600;
    font-style: normal;
    font-display: swap;
  }

  @font-face {
    font-family: "Montserrat";
    src:
      url("/fonts/Montserrat-Bold.woff2") format("woff2"),
      url("/fonts/Montserrat-Bold.woff") format("woff");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
  }

  @font-face {
    font-family: "Montserrat";
    src:
      url("/fonts/Montserrat-ExtraBold.woff2") format("woff2"),
      url("/fonts/Montserrat-ExtraBold.woff") format("woff");
    font-weight: 800;
    font-style: normal;
    font-display: swap;
  }

  @font-face {
    font-family: "Montserrat";
    src:
      url("/fonts/Montserrat-Black.woff2") format("woff2"),
      url("/fonts/Montserrat-Black.woff") format("woff");
    font-weight: 900;
    font-style: normal;
    font-display: swap;
  }
}

* {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

*::-webkit-scrollbar {
  display: none;
}

.grainy:before {
  content: "";
  background-color: transparent;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 600 600'%3E%3Cfilter id='a'%3E%3CfeTurbulence type='turbulence' baseFrequency='.07' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23a)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 182px;
  opacity: 0.08;
  top: 0;
  left: 0;
  position: absolute;
  width: 100%;
  height: 100%;
}

.pattern-1 {
  --s: 32px;

  --g1: conic-gradient(at 37.5% 87.5%, #0000 75%, var(--color-custom-4) 0);
  --g2: conic-gradient(at 12.5% 62.5%, #0000 75%, var(--color-custom-3) 0);
  background:
    var(--g2) calc(var(--s) / 4) calc(var(--s) / 4),
    var(--g2) calc(5 * var(--s) / 4) calc(5 * var(--s) / 4),
    var(--g1),
    var(--g1) var(--s) var(--s) var(--color-custom-3);
  background-size: calc(2 * var(--s)) calc(2 * var(--s));
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Montserrat", sans-serif;
  background-color: var(--color-custom-2);
  color: var(--color-custom-3);
  line-height: 1.6;
}

@keyframes marquee {
  0% {
    transform: translateX(0%);
  }
  100% {
    transform: translateX(-50%);
  }
}

.animate-marquee {
  animation: marquee 25s linear infinite;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-fade-in-up {
  animation: fadeInUp 0.6s ease-out;
}

.gradient-text {
  background: linear-gradient(
    135deg,
    var(--color-custom-1),
    var(--color-custom-3)
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.btn-custom-1 {
  background: var(--color-custom-1);
  color: var(--color-custom-2);
  padding: 0.75rem 2rem;
  border-radius: 0.5rem;
  font-weight: 600;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
}

.btn-custom-1:hover {
  background: var(--color-custom-3);
  transform: translateY(-2px);
}

.btn-custom-2 {
  background: transparent;
  color: var(--color-custom-3);
  padding: 0.75rem 2rem;
  border-radius: 0.5rem;
  font-weight: 600;
  transition: all 0.3s ease;
  border: 2px solid var(--color-custom-3);
  cursor: pointer;
}

.btn-custom-2:hover {
  border-color: var(--color-custom-1);
  color: var(--color-custom-1);
}

.card-modern {
  background: var(--color-custom-2);
  border-radius: 1rem;
  padding: 2rem;
  border: 1px solid var(--color-custom-3);
  transition: all 0.3s ease;
}

.card-modern:hover {
  border-color: var(--color-custom-1);
  transform: translateY(-4px);
}

.section-padding {
  padding: 3rem 0;
}

@media (min-width: 768px) {
  .section-padding {
    padding: 4rem 0;
  }
}

@media (min-width: 1024px) {
  .section-padding {
    padding: 6rem 0;
  }
}

.section-padding-sm {
  padding: 2rem 0;
}

@media (min-width: 768px) {
  .section-padding-sm {
    padding: 3rem 0;
  }
}

@media (min-width: 1024px) {
  .section-padding-sm {
    padding: 4rem 0;
  }
}

.heading-xl {
  font-size: clamp(2rem, 6vw, 4rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.heading-lg {
  font-size: clamp(1.75rem, 5vw, 3rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.heading-md {
  font-size: clamp(1.25rem, 4vw, 2rem);
  font-weight: 600;
  line-height: 1.3;
}

.text-large {
  font-size: 1rem;
  line-height: 1.6;
}

@media (min-width: 768px) {
  .text-large {
    font-size: 1.125rem;
    line-height: 1.7;
  }
}

/* Mobile-first responsive utilities */
.mobile-center {
  text-align: center;
}

@media (min-width: 768px) {
  .mobile-center {
    text-align: left;
  }
}

.mobile-stack {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@media (min-width: 768px) {
  .mobile-stack {
    flex-direction: row;
    gap: 2rem;
  }
}

.mobile-full {
  width: 100%;
}

@media (min-width: 768px) {
  .mobile-full {
    width: auto;
  }
}

/* Enhanced responsive utilities */
.responsive-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 768px) {
  .responsive-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
}

@media (min-width: 1024px) {
  .responsive-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }
}

.responsive-text {
  font-size: 0.875rem;
  line-height: 1.5;
}

@media (min-width: 768px) {
  .responsive-text {
    font-size: 1rem;
    line-height: 1.6;
  }
}

@media (min-width: 1024px) {
  .responsive-text {
    font-size: 1.125rem;
    line-height: 1.7;
  }
}

.responsive-spacing {
  padding: 1rem;
}

@media (min-width: 768px) {
  .responsive-spacing {
    padding: 1.5rem;
  }
}

@media (min-width: 1024px) {
  .responsive-spacing {
    padding: 2rem;
  }
}

/* Mobile-optimized form styles */
.mobile-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@media (min-width: 768px) {
  .mobile-form {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }
}

.mobile-form-full {
  grid-column: 1 / -1;
}

/* Improved mobile navigation */
.mobile-nav-item {
  display: block;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  font-weight: 500;
  border-radius: 0.5rem;
  transition: all 0.2s ease;
}

@media (min-width: 1024px) {
  .mobile-nav-item {
    display: inline-block;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 400;
    border-radius: 9999px;
  }
}

/* Touch-friendly buttons */
@media (max-width: 767px) {
  .btn-custom-1,
  .btn-custom-2 {
    min-height: 44px;
    padding: 0.875rem 1.5rem;
  }
}

/* Shimmer effect */
@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

.shimmer {
  position: relative;
  overflow: hidden;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(22, 163, 74, 0.3) 50%,
    rgba(22, 163, 74, 0.6) 75%,
    transparent 100%
  );
  background-size: 200% 100%;
  animation: shimmer 3s linear infinite;
  padding: 8px 16px;
  border-radius: 100px;
  transition: all 0.3s ease;
}

/* Custom scrollbar for sidebar */
.scrollbar-thin {
  scrollbar-width: thin;
  scrollbar-color: rgba(245, 245, 245, 0.2) transparent;
}

.scrollbar-thin::-webkit-scrollbar {
  width: 6px;
}

.scrollbar-thin::-webkit-scrollbar-track {
  background: transparent;
}

.scrollbar-thin::-webkit-scrollbar-thumb {
  background-color: rgba(245, 245, 245, 0.2);
  border-radius: 3px;
}

.scrollbar-thin::-webkit-scrollbar-thumb:hover {
  background-color: rgba(245, 245, 245, 0.3);
}

/* Rich Text Section - Global Styles */
.rich-text-content {
  font-family: inherit;
  color: #95999A;
  width: 100%;
}

/* Headings */
.rich-text-content h1 {
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1.2;
  margin-top: 2rem;
  margin-bottom: 1.5rem;
  letter-spacing: -0.025em;
}

.rich-text-content h2 {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.3;
  margin-top: 2rem;
  margin-bottom: 1.25rem;
  letter-spacing: -0.025em;
}

.rich-text-content h3 {
  font-size: 1.5rem;
  font-weight: 600;
  line-height: 1.4;
  margin-top: 1.75rem;
  margin-bottom: 1rem;
}

.rich-text-content h4 {
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.4;
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
}

.rich-text-content h5 {
  font-size: 1.125rem;
  font-weight: 600;
  line-height: 1.4;
  margin-top: 1.25rem;
  margin-bottom: 0.5rem;
}

.rich-text-content h6 {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.4;
  margin-top: 1rem;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Paragraphs */
.rich-text-content p {
  font-size: 1rem;
  line-height: 1.6;
  margin-top: 0;
  margin-bottom: 1rem;
  text-align: left;
}

.rich-text-content p:last-child {
  margin-bottom: 0;
}

/* Links */
.rich-text-content a {
  text-decoration: none;
  transition: color 0.2s ease, text-decoration 0.2s ease;
}

.rich-text-content a:hover {
  text-decoration: underline;
}

.rich-text-content a:focus {
  outline: 2px solid currentColor;
  outline-offset: 2px;
  border-radius: 2px;
}

/* Lists */
.rich-text-content ul,
.rich-text-content ol {
  margin-top: 0.75rem;
  margin-bottom: 1.25rem;
  padding-left: 1.5rem;
}

.rich-text-content ul {
  list-style-type: disc;
}

.rich-text-content ol {
  list-style-type: decimal;
}

.rich-text-content li {
  margin-bottom: 0.5rem;
  line-height: 1.5;
}

.rich-text-content li:last-child {
  margin-bottom: 0;
}

.rich-text-content ul ul,
.rich-text-content ol ol,
.rich-text-content ul ol,
.rich-text-content ol ul {
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

.rich-text-content ul ul,
.rich-text-content ol ul {
  list-style-type: circle;
}

.rich-text-content ul ul ul,
.rich-text-content ol ul ul {
  list-style-type: square;
}

/* Blockquotes */
.rich-text-content blockquote {
  margin: 1.5rem 0;
  padding: 1rem 1.5rem;
  border-left: 4px solid;
  font-style: italic;
  border-radius: 0 0.375rem 0.375rem 0;
}

.rich-text-content blockquote p {
  margin-bottom: 0.5rem;
}

.rich-text-content blockquote p:last-child {
  margin-bottom: 0;
}

.rich-text-content blockquote cite {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.875rem;
  font-style: normal;
  font-weight: 500;
}

/* Code */
.rich-text-content code {
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
  font-size: 0.875rem;
  padding: 0.125rem 0.375rem;
  border-radius: 0.25rem;
}

.rich-text-content pre {
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
  font-size: 0.875rem;
  padding: 1rem;
  border-radius: 0.375rem;
  overflow-x: auto;
  margin: 1.25rem 0;
  line-height: 1.5;
}

.rich-text-content pre code {
  background-color: transparent;
  padding: 0;
  font-size: inherit;
}

/* Tables - Updated to work with wrapper */
.rich-text-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.875rem;
}

.rich-text-content thead {
  border-bottom: 2px solid;
}

.rich-text-content th {
  padding: 0.75rem 1rem;
  text-align: left;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  color: black;
}

.rich-text-content td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid;
}

.rich-text-content tbody tr:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

.rich-text-content tbody tr:last-child td {
  border-bottom: none;
}

/* Table Scroll Wrapper - New addition */
.table-scroll-wrapper {
  width: 100%;
  overflow-x: auto;
  margin: 1.5rem 0;
  -webkit-overflow-scrolling: touch;
}

/* Update table styles inside wrapper */
.table-scroll-wrapper table {
  width: auto;
  min-width: 100%;
  margin: 0;
}

.table-scroll-wrapper thead {
  border-bottom: 2px solid;
}

.table-scroll-wrapper th {
  padding: 0.75rem 1rem;
  text-align: left;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  color: black;
}

.table-scroll-wrapper td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid;
}

.table-scroll-wrapper tbody tr:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

.table-scroll-wrapper tbody tr:last-child td {
  border-bottom: none;
}

/* Horizontal Rules */
.rich-text-content hr {
  margin: 2rem 0;
  border: 0;
  height: 1px;
}

/* Images */
.rich-text-content img {
  max-width: 100%;
  height: auto;
  border-radius: 0.375rem;
  margin: 1.5rem 0;
}

/* Text Formatting */
.rich-text-content strong,
.rich-text-content b {
  font-weight: 700;
}

.rich-text-content em,
.rich-text-content i {
  font-style: italic;
}

.rich-text-content u {
  text-decoration: underline;
}

.rich-text-content s,
.rich-text-content del {
  text-decoration: line-through;
}

.rich-text-content ins {
  text-decoration: underline;
  padding: 0.125rem 0.25rem;
  border-radius: 0.125rem;
}

.rich-text-content mark {
  padding: 0.125rem 0.25rem;
  border-radius: 0.125rem;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .rich-text-content h1 {
    font-size: 2rem;
  }
  
  .rich-text-content h2 {
    font-size: 1.75rem;
  }
  
  .rich-text-content h3 {
    font-size: 1.375rem;
  }
  
  .rich-text-content h4 {
    font-size: 1.125rem;
  }
  
  .rich-text-content p,
  .rich-text-content li,
  .rich-text-content td {
    font-size: 0.9375rem;
  }
  
  .rich-text-content table {
    font-size: 0.8125rem;
  }
  
  .rich-text-content th {
    font-size: 0.6875rem;
  }
}

/* Small Mobile (320px - 375px) */
@media (max-width: 376px) {
  .table-scroll-wrapper {
    width: 300px;
  }
}

/* Medium Mobile (376px - 425px) */
@media (min-width: 377px) and (max-width: 426px) {
  .table-scroll-wrapper {
    width: 370px;
  }
}

/* Large Mobile (426px - 767px) */
@media (min-width: 427px) and (max-width: 768px) {
  .table-scroll-wrapper {
    width: 700px;
  }
}

/* Tablet (768px and above) - Remove fixed width */
@media (min-width: 769px) {
  .table-scroll-wrapper {
    width: 100%;
    overflow-x: visible;
  }
}