/**
 * Home Page Styles
 * 
 * @package Coderr_ProLive
 */

/* Landing Page Layout - убираем сайдбар */
.page-template-template-home .content-area,
.home.page .content-area {
  padding: 0;
}

.page-template-template-home .content-wrapper,
.home.page .content-wrapper {
  grid-template-columns: 1fr;
  gap: 0;
}

.page-template-template-home .widget-area,
.home.page .widget-area {
  display: none;
}

.home-page {
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0;
}

/* Hero Section */
.hero-section {
  background: var(--gradient-primary);
  color: var(--white);
  padding: 100px 0 140px;
  position: relative;
  overflow: hidden;
  width: 100%;
  margin: 0;
  margin-top: 80px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
  pointer-events: none;
}

/* Hero Section с фоновым изображением */
.hero-section-with-image {
  background-color: rgba(0, 0, 0, 0.3);
}

.hero-section-with-image::before {
  background: rgba(0, 0, 0, 0.4);
  background-image: none;
}

.hero-content {
  display: grid;
  grid-template-columns: 1fr;
  gap: 60px;
  align-items: center;
  position: relative;
  z-index: 1;
  max-width: 1400px;
  margin: 0 auto;
}

.hero-title {
  font-size: 3rem;
  line-height: 1.2;
  margin-bottom: 20px;
  color: var(--white);
}

.hero-title .highlight {
  color: var(--white);
  display: block;
  opacity: 0.95;
}

.hero-description {
  font-size: 1.2rem;
  line-height: 1.6;
  margin-bottom: 30px;
  opacity: 0.95;
}

.hero-actions {
  display: flex;
  gap: 15px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.hero-actions .btn {
  background: var(--white);
  color: var(--primary-color);
}

.hero-actions .btn:hover {
  background: rgba(255, 255, 255, 0.9);
  color: var(--primary-color);
}

.hero-actions .btn-secondary {
  background: transparent;
  border-color: var(--white);
  color: var(--white);
}

.hero-actions .btn-secondary:hover {
  background: var(--white);
  color: var(--primary-color);
}

.hero-features {
  display: flex;
  gap: 30px;
  flex-wrap: wrap;
}

.hero-feature {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 600;
}

.hero-feature svg {
  flex-shrink: 0;
  stroke: var(--white);
}

.hero-image {
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-image img {
  max-width: 100%;
  height: auto;
  filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.2));
}

/* Section Common Styles */
.section-header {
  text-align: center;
  max-width: 1000px;
  margin: 0 auto 50px;
}

.section-title {
  font-size: 2.5rem;
  margin-bottom: 15px;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: var(--gradient-primary);
  border-radius: 2px;
}

.section-description {
  font-size: 1.1rem;
  color: var(--gray);
  margin-top: 20px;
}

/* Services Section */
.services-section {
  padding: 80px 0;
  background: var(--bg-secondary);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 30px;
}

.service-card {
  background: var(--bg-card);
  padding: 40px 30px;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-card);
  transition: var(--transition);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gradient-primary);
  transform: scaleX(0);
  transition: var(--transition);
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-hover);
  border: 1px solid var(--primary-pale);
}

.service-card:hover::before {
  transform: scaleX(1);
}

.service-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 25px;
  background: var(--gradient-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.service-card:hover .service-icon {
  transform: scale(1.1) rotate(5deg);
}

.service-icon i {
  font-size: 40px;
  color: var(--white);
  display: block;
}

.service-title {
  font-size: 1.5rem;
  margin-bottom: 15px;
  color: var(--dark-color);
}

.service-description {
  color: var(--gray);
  margin-bottom: 20px;
  line-height: 1.6;
}

.service-link {
  color: var(--primary-color);
  font-weight: 600;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.service-link:hover {
  gap: 10px;
}

/* Fire Systems Section */
.fire-systems-section {
  padding: 80px 0;
  background: var(--bg-primary);
}

.fire-systems-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 40px;
  margin-top: 50px;
}

.fire-system-item {
  text-align: center;
  padding: 30px 20px;
  background: var(--bg-card);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-card);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.fire-system-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-primary);
  transform: scaleX(0);
  transition: var(--transition);
}

.fire-system-item:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
}

.fire-system-item:hover::before {
  transform: scaleX(1);
}

.fire-system-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 25px;
  background: var(--gradient-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  transition: var(--transition);
}

.fire-system-item:hover .fire-system-icon {
  transform: scale(1.1) rotate(5deg);
}

.fire-system-icon svg {
  stroke: var(--white);
  width: 48px;
  height: 48px;
}

.fire-system-title {
  font-size: 1.25rem;
  line-height: 1.4;
  color: var(--dark-color);
  font-weight: 600;
  margin: 0;
}

/* Licenses Section */
.licenses-section {
  padding: 160px 0;
  background: var(--bg-secondary);
}

.licenses-wrapper {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 40px;
  align-items: start;
  max-width: 1200px;
  margin: 0 auto;
}

.licenses-image-wrapper {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  flex-shrink: 0;
}

.licenses-image-wrapper {
  cursor: pointer;
}

.licenses-image-link {
  display: block;
  transition: transform 0.3s ease;
}

.licenses-image-link:hover {
  transform: scale(1.05);
}

.licenses-image-wrapper img,
.licenses-image {
  max-width: 350px !important;
  width: auto !important;
  height: auto !important;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-card);
  border: 1px solid rgba(0, 0, 0, 0.1);
  transition: box-shadow 0.3s ease;
}

.licenses-image-wrapper:hover img {
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

/* License Lightbox */
.license-lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.license-lightbox.active {
  opacity: 1;
  visibility: visible;
}

.license-lightbox-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
}

.license-lightbox-content {
  position: relative;
  z-index: 10000;
  max-width: 90%;
  max-height: 90%;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: lightboxFadeIn 0.3s ease;
}

@keyframes lightboxFadeIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.license-lightbox-image {
  max-width: 100%;
  max-height: 90vh;
  width: auto;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.license-lightbox-close {
  position: fixed;
  top: 60px;
  right: 20px;
  background: none;
  border: none;
  border-radius: 0;
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.7);
  transition: all 0.3s ease;
  z-index: 10001;
  box-shadow: none;
}

.license-lightbox-close:hover {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 1);
  transform: rotate(90deg) scale(1.1);
  box-shadow: none;
}

.license-lightbox-close svg {
  width: 36px;
  height: 36px;
  stroke-width: 2.5;
}

body.lightbox-open {
  overflow: hidden;
}

.licenses-content {
  padding-left: 40px;
  border-left: 4px solid var(--primary-color);
  position: relative;
}

.licenses-content::before {
  content: '';
  position: absolute;
  left: -4px;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--gradient-primary);
}

.licenses-title {
  font-size: 2rem;
  margin-bottom: 15px;
  color: var(--dark-color);
  font-weight: 700;
}

.licenses-subtitle {
  font-size: 1.25rem;
  margin-bottom: 20px;
  color: var(--primary-color);
  font-weight: 600;
}

.licenses-text {
  font-size: 1.125rem;
  line-height: 1.8;
  color: var(--gray);
  margin: 0;
}

/* Why Us Section */
.why-us-section {
  padding: 120px 0;
  background: var(--bg-secondary);
}

.why-us-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
}

.why-us-card {
  text-align: center;
  position: relative;
}

.why-us-number {
  font-size: 4rem;
  font-weight: 700;
  color: var(--primary-color);
  line-height: 1;
  margin-bottom: 20px;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.why-us-card h3 {
  font-size: 1.5rem;
  margin-bottom: 15px;
  color: var(--dark-color);
}

.why-us-card p {
  color: var(--gray);
  line-height: 1.6;
}

/* CTA Section */
.cta-section {
  padding: 80px 0;
  background: var(--gradient-primary);
  color: var(--white);
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 100%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
  animation: pulse 4s ease-in-out infinite;
}

.cta-content {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.cta-title {
  font-size: 2.5rem;
  margin-bottom: 20px;
  color: var(--white);
}

.cta-description {
  font-size: 1.2rem;
  margin-bottom: 40px;
  opacity: 0.9;
}

.cta-actions {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn-large {
  padding: 16px 40px;
  font-size: 18px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.cta-actions .btn {
  background: var(--accent-red);
  color: var(--white);
}

.cta-actions .btn:hover {
  background: var(--accent-red-dark);
}

.cta-actions .btn-secondary {
  background: transparent;
  border-color: var(--white);
  color: var(--white);
}

.cta-actions .btn-secondary:hover {
  background: var(--white);
  color: var(--primary-color);
}

/* Latest Posts Section */
.latest-posts-section {
  padding: 80px 0;
  background: var(--bg-secondary);
}

.latest-posts-section .section-header {
  text-align: center;
  max-width: 100%;
  margin-bottom: 50px;
  position: relative;
}

.latest-posts-section .section-title {
  margin-bottom: 15px;
  display: inline-block;
}

.latest-posts-section .section-title::after {
  display: block;
}

.latest-posts-section .view-all {
  position: absolute;
  top: 0;
  right: 0;
}

.latest-posts-section .posts-grid {
  justify-items: center;
}

.view-all {
  color: var(--primary-color);
  font-weight: 600;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 5px;
}

.view-all:hover {
  gap: 10px;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .hero-content {
    gap: 40px;
  }

  .hero-title {
    font-size: 2.5rem;
  }

  .section-title {
    font-size: 2rem;
  }

  .services-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }
}

@media (max-width: 768px) {
  .hero-section {
    padding: 60px 0 100px;
  }

  .hero-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .hero-image {
    order: -1;
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-description {
    font-size: 1rem;
  }

  .hero-features {
    flex-direction: column;
    gap: 15px;
  }

  .section-title {
    font-size: 1.75rem;
  }

  .section-description {
    font-size: 1rem;
  }

  .services-section,
  .why-us-section,
  .fire-systems-section,
  .licenses-section,
  .latest-posts-section {
    padding: 120px 0;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .why-us-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .fire-systems-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .licenses-wrapper {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .licenses-image-wrapper {
    justify-content: center;
  }

  .licenses-image-wrapper img {
    max-width: 350px;
  }

  .license-lightbox-close {
    top: 50px;
    right: 15px;
    width: 50px;
    height: 50px;
    background: none;
    border: none;
  }

  .license-lightbox-close svg {
    width: 32px;
    height: 32px;
  }

  .license-lightbox-content {
    max-width: 95%;
    max-height: 95%;
  }

  .license-lightbox-image {
    max-height: 85vh;
  }

  .licenses-content {
    padding-left: 0;
    padding-top: 20px;
    border-left: none;
    border-top: 4px solid var(--primary-color);
  }

  .licenses-content::before {
    display: none;
  }

  .cta-section {
    padding: 60px 0;
  }

  .cta-title {
    font-size: 2rem;
  }

  .cta-description {
    font-size: 1rem;
  }

  .cta-actions {
    flex-direction: column;
  }

  .btn-large {
    width: 100%;
    justify-content: center;
  }

  .latest-posts-section .section-header {
    text-align: center;
  }

  .latest-posts-section .view-all {
    position: static;
    margin-top: 20px;
    display: inline-block;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 1.75rem;
  }

  .hero-actions {
    flex-direction: column;
  }

  .hero-actions .btn {
    width: 100%;
    text-align: center;
  }

  .section-title {
    font-size: 1.5rem;
  }

  .service-card {
    padding: 30px 20px;
  }

  .why-us-number {
    font-size: 3rem;
  }

  .cta-title {
    font-size: 1.75rem;
  }

  .btn-large {
    padding: 14px 30px;
    font-size: 16px;
  }
}

