/* ═══════════════════════════════════════════════════════════════════════════
   HOMEPAGE CUSTOM STYLES
   ═══════════════════════════════════════════════════════════════════════════ */

/* Hero Section */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding: 2rem;
}

.hero-container {
  position: relative;
  width: 100%;
  max-width: 1200px;
  text-align: center;
}

/* Animated Grid */
.hero-grid {
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background-image:
    linear-gradient(rgba(16, 185, 129, 0.1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(16, 185, 129, 0.1) 1px, transparent 1px);
  background-size: 50px 50px;
  transform: perspective(500px) rotateX(60deg);
  animation: grid-scroll 20s linear infinite;
  pointer-events: none;
}

@keyframes grid-scroll {
  0% { transform: perspective(500px) rotateX(60deg) translateY(0); }
  100% { transform: perspective(500px) rotateX(60deg) translateY(50px); }
}

/* Floating Buildings */
.floating-buildings {
  position: absolute;
  bottom: 10%;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 600px;
  height: 150px;
  pointer-events: none;
  opacity: 0.15;
}

.building {
  position: absolute;
  bottom: 0;
  background: linear-gradient(180deg, var(--rci-commercial), var(--rci-residential));
  animation: building-float 4s ease-in-out infinite;
}

.b1 { left: 10%; width: 30px; height: 80px; animation-delay: 0s; }
.b2 { left: 25%; width: 40px; height: 120px; animation-delay: 0.5s; }
.b3 { left: 45%; width: 50px; height: 100px; animation-delay: 1s; }
.b4 { left: 65%; width: 35px; height: 90px; animation-delay: 1.5s; }
.b5 { left: 80%; width: 45px; height: 110px; animation-delay: 2s; }

@keyframes building-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* Hero Content */
.hero-content {
  position: relative;
  z-index: 10;
}

/* Logo */
.hero-logo {
  position: relative;
  display: inline-block;
  margin-bottom: 2rem;
}

.hero-logo img {
  width: 150px;
  height: 150px;
  border-radius: 16px;
  border: 3px solid var(--rci-residential);
  box-shadow: 0 0 40px rgba(16, 185, 129, 0.3);
  animation: logo-pulse 3s ease-in-out infinite;
}

.logo-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.2) 0%, transparent 70%);
  animation: glow-pulse 3s ease-in-out infinite;
  pointer-events: none;
}

@keyframes logo-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.02); }
}

@keyframes glow-pulse {
  0%, 100% { opacity: 0.5; transform: translate(-50%, -50%) scale(1); }
  50% { opacity: 1; transform: translate(-50%, -50%) scale(1.1); }
}

/* Title */
.hero-title {
  font-family: var(--font-pixel) !important;
  font-size: clamp(1.2rem, 5vw, 2rem) !important;
  background: linear-gradient(135deg, var(--rci-residential), var(--rci-commercial), var(--rci-industrial));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.hero-subtitle {
  font-family: var(--font-body);
  font-size: 1.2rem;
  color: var(--text-secondary);
  max-width: 500px;
  margin: 0 auto 2rem;
  line-height: 1.6;
}

/* RCI Indicator */
.rci-indicator {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.rci-bar {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.rci-label {
  font-family: var(--font-pixel);
  font-size: 0.6rem;
  color: var(--text-muted);
}

.rci-fill {
  width: 8px;
  height: 60px;
  background: var(--bg-tertiary);
  border-radius: 4px;
  position: relative;
  overflow: hidden;
}

.rci-fill::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: currentColor;
  border-radius: 4px;
  animation: rci-grow 2s ease-out forwards;
}

.residential .rci-fill { color: var(--rci-residential); }
.residential .rci-fill::after { height: 80%; animation-delay: 0.2s; }

.commercial .rci-fill { color: var(--rci-commercial); }
.commercial .rci-fill::after { height: 60%; animation-delay: 0.4s; }

.industrial .rci-fill { color: var(--rci-industrial); }
.industrial .rci-fill::after { height: 40%; animation-delay: 0.6s; }

@keyframes rci-grow {
  0% { height: 0; }
}

/* Hero Buttons */
.hero-buttons {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero-btn {
  font-family: var(--font-mono) !important;
  font-size: 0.9rem;
  padding: 1rem 2rem;
  background: transparent;
  border: 2px solid var(--rci-residential);
  border-radius: 8px;
  color: var(--rci-residential) !important;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.hero-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
  transition: left 0.5s ease;
}

.hero-btn:hover {
  background: var(--rci-residential);
  color: var(--bg-primary) !important;
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(16, 185, 129, 0.3);
}

.hero-btn:hover::before {
  left: 100%;
}

.hero-btn:nth-child(2) {
  border-color: var(--rci-commercial);
  color: var(--rci-commercial) !important;
}

.hero-btn:nth-child(2):hover {
  background: var(--rci-commercial);
  box-shadow: 0 10px 30px rgba(6, 182, 212, 0.3);
}

.hero-btn:nth-child(3) {
  border-color: var(--rci-industrial);
  color: var(--rci-industrial) !important;
}

.hero-btn:nth-child(3):hover {
  background: var(--rci-industrial);
  box-shadow: 0 10px 30px rgba(245, 158, 11, 0.3);
}

.btn-icon {
  transition: transform 0.3s ease;
}

.hero-btn:hover .btn-icon {
  transform: translateX(3px);
}

/* Scroll Indicator */
.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  animation: bounce 2s infinite;
}

.scroll-arrow {
  font-size: 1.2rem;
  animation: arrow-bounce 1s infinite;
}

@keyframes bounce {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

@keyframes arrow-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(5px); }
}

/* ═══════════════════════════════════════════════════════════════════════════
   GUIDES SECTION
   ═══════════════════════════════════════════════════════════════════════════ */

.guides-section {
  padding: 6rem 2rem;
  background: var(--bg-secondary);
  position: relative;
}

.guides-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100px;
  background: linear-gradient(180deg, var(--bg-primary), transparent);
}

.section-container {
  max-width: 1200px;
  margin: 0 auto;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 3rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.section-title {
  font-family: var(--font-pixel) !important;
  font-size: clamp(0.8rem, 3vw, 1.2rem) !important;
  color: var(--text-primary) !important;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border: none !important;
  padding: 0 !important;
  margin: 0 !important;
}

.section-title::before {
  display: none !important;
}

.title-prefix {
  color: var(--rci-commercial);
  opacity: 0.5;
}

.view-all {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--rci-residential) !important;
  transition: all 0.3s ease;
}

.view-all:hover {
  color: var(--rci-commercial) !important;
  transform: translateX(5px);
}

/* Guides Grid */
.guides-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 2rem;
}

.guide-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  animation: fadeInUp 0.6s ease forwards;
  opacity: 0;
}

.guide-card:nth-child(1) { animation-delay: 0.1s; }
.guide-card:nth-child(2) { animation-delay: 0.2s; }
.guide-card:nth-child(3) { animation-delay: 0.3s; }
.guide-card:nth-child(4) { animation-delay: 0.4s; }
.guide-card:nth-child(5) { animation-delay: 0.5s; }
.guide-card:nth-child(6) { animation-delay: 0.6s; }

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.guide-card:hover {
  transform: translateY(-10px);
  border-color: var(--rci-residential);
  box-shadow: 0 20px 60px rgba(16, 185, 129, 0.15);
}

.card-link {
  display: block;
  text-decoration: none;
}

.card-image {
  position: relative;
  height: 200px;
  overflow: hidden;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.guide-card:hover .card-image img {
  transform: scale(1.1);
}

.card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(0, 0, 0, 0.8) 100%);
}

.card-content {
  padding: 1.5rem;
}

.card-meta {
  display: flex;
  gap: 1rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.card-title {
  font-family: var(--font-pixel) !important;
  font-size: 0.7rem !important;
  color: var(--text-primary) !important;
  margin-bottom: 0.75rem;
  line-height: 1.5;
  border: none !important;
  padding: 0 !important;
}

.card-title::before {
  display: none !important;
}

.card-summary {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.card-tags {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.tag {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  padding: 0.25rem 0.6rem;
  background: var(--bg-tertiary);
  border-radius: 4px;
  color: var(--text-muted);
}

/* ═══════════════════════════════════════════════════════════════════════════
   STATS SECTION
   ═══════════════════════════════════════════════════════════════════════════ */

.stats-section {
  padding: 4rem 2rem;
  background: var(--bg-primary);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  max-width: 800px;
  margin: 0 auto;
}

.stat-card {
  text-align: center;
  padding: 2rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  transition: all 0.3s ease;
}

.stat-card:hover {
  transform: translateY(-5px);
  border-color: var(--rci-commercial);
  box-shadow: 0 10px 40px rgba(6, 182, 212, 0.1);
}

.stat-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.stat-number {
  font-family: var(--font-pixel);
  font-size: 1.5rem;
  color: var(--rci-residential);
  margin-bottom: 0.5rem;
}

.stat-label {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ═══════════════════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════════════════ */

@media (max-width: 768px) {
  .hero-section {
    min-height: 90vh;
    padding: 4rem 1rem;
  }

  .hero-logo img {
    width: 120px;
    height: 120px;
  }

  .hero-buttons {
    flex-direction: column;
    align-items: center;
  }

  .hero-btn {
    width: 100%;
    max-width: 280px;
    justify-content: center;
  }

  .guides-grid {
    grid-template-columns: 1fr;
  }

  .floating-buildings {
    display: none;
  }

  .scroll-indicator {
    display: none;
  }
}
