/* ============================================
   MIDNIGHT CIRCUIT - Smart Home Setup Theme
   Glassmorphism & Cyber-Minimal Design
   ============================================ */

:root {
  /* Color Palette - Midnight Circuit */
  --color-bg-primary: #121212;
  --color-bg-secondary: #1a1a1a;
  --color-bg-glass: rgba(26, 26, 26, 0.6);
  --color-accent-cyan: #00F2FF;
  --color-accent-purple: #8A2BE2;
  --color-text-primary: #E0E0E0;
  --color-text-secondary: #B0B0B0;
  --color-border: rgba(224, 224, 224, 0.1);
  
  /* Typography */
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-heading: 'Orbitron', 'Inter', sans-serif;
  
  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 2rem;
  --space-xl: 3rem;
  --space-xxl: 4rem;
  
  /* Border Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  
  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 20px rgba(0, 242, 255, 0.3);
  --shadow-purple: 0 0 20px rgba(138, 43, 226, 0.3);
  
  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;
}

/* ============================================
   RESET & BASE STYLES
   ============================================ */

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

html {
  font-size: 16px;
  overflow-x: hidden;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  background-color: var(--color-bg-primary);
  color: var(--color-text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  text-decoration: none;
  color: var(--color-accent-cyan);
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-accent-purple);
}

/* ============================================
   TYPOGRAPHY
   ============================================ */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: var(--space-md);
  color: var(--color-text-primary);
}

h1 {
  font-size: clamp(1.5rem, 4vw, 3rem);
}

h2 {
  font-size: clamp(1.3rem, 3vw, 2rem);
}

h3 {
  font-size: clamp(1.2rem, 2vw, 1.6rem);
}

h4 {
  font-size: clamp(1rem, 1.5vw, 1.3rem);
}

p {
  margin-bottom: var(--space-md);
  color: var(--color-text-secondary);
}

/* ============================================
   HEADER & NAVIGATION
   ============================================ */

.header-container {
  position: relative;
  width: 100%;
  padding: var(--space-md) var(--space-lg);
  background: var(--color-bg-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--color-border);
  z-index: 1000;
}

.header-wrapper {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-md);
  position: relative;
}

.brand-text {
  font-family: var(--font-heading);
  font-size: clamp(1rem, 2vw, 1.35rem);
  font-weight: 700;
  color: var(--color-accent-cyan);
  text-transform: uppercase;
  position: relative;
}

.brand-text::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--color-accent-cyan), var(--color-accent-purple));
  opacity: 0.6;
}

.nav-menu {
  display: flex;
  list-style: none;
  align-items: center;
  flex-wrap: wrap;
}

.nav-link {
  color: var(--color-text-primary);
  font-size: 0.95rem;
  font-weight: 500;
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
  position: relative;
}

.nav-link::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 2px;
  background: var(--color-accent-cyan);
  transition: width var(--transition-base);
}

.nav-link:hover::before {
  width: 80%;
}

.nav-link:hover {
  color: var(--color-accent-cyan);
}

/* Burger Menu */
.burger-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-sm);
  cursor: pointer;
  flex-direction: column;
  gap: 4px;
  width: 40px;
  height: 40px;
  justify-content: center;
  align-items: center;
  transition: all var(--transition-base);
  position: absolute;
  right: var(--space-lg);
  top: 50%;
  transform: translateY(-50%);
  z-index: 10001;
}

.burger-toggle:hover {
  border-color: var(--color-accent-cyan);
  box-shadow: var(--shadow-glow);
}

.burger-line {
  width: 24px;
  height: 2px;
  background: var(--color-text-primary);
  border-radius: 2px;
  transition: all var(--transition-base);
}

.burger-toggle.active .burger-line:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
}

.burger-toggle.active .burger-line:nth-child(2) {
  opacity: 0;
}

.burger-toggle.active .burger-line:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

.mobile-nav {
  display: none;
  position: fixed;
  top: 0;
  right: -100%;
  width: 280px;
  height: 100vh;
  background: var(--color-bg-glass);
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px);
  border-left: 1px solid var(--color-border);
  padding: var(--space-xl) var(--space-lg);
  z-index: 10000;
  transition: right var(--transition-base);
  box-shadow: var(--shadow-lg);
}

.mobile-nav.active {
  right: 0;
}

.mobile-nav-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  margin-top: var(--space-xl);
}

.mobile-nav-link {
  color: var(--color-text-primary);
  font-size: 1.1rem;
  padding: var(--space-md);
  border-radius: var(--radius-md);
  display: block;
  transition: all var(--transition-base);
  border: 1px solid transparent;
}

.mobile-nav-link:hover {
  background: var(--color-bg-glass);
  border-color: var(--color-accent-cyan);
  color: var(--color-accent-cyan);
  padding-left: var(--space-lg);
}


/* ============================================
   HERO BANNERS (Full-Width)
   ============================================ */

.hero-banner {
  width: 100vw;
  position: relative;
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin-left: calc(-50vw + 50%);
  margin-right: calc(-50vw + 50%);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-image {
  display: none;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    135deg,
    rgba(18, 18, 18, 0.85) 0%,
    rgba(26, 26, 26, 0.75) 50%,
    rgba(138, 43, 226, 0.3) 100%
  );
  z-index: 2;
}

.hero-content {
  position: relative;
  z-index: 3;
  max-width: 1200px;
  padding: var(--space-xl) var(--space-lg);
  text-align: center;
  width: 100%;
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  margin-bottom: var(--space-lg);
  background: linear-gradient(135deg, var(--color-accent-cyan), var(--color-accent-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: 0 0 30px rgba(0, 242, 255, 0.5);
}

.hero-description {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  max-width: 800px;
  margin: 0 auto var(--space-xl);
  color: var(--color-text-primary);
  line-height: 1.8;
}

.hero-cta {
  display: inline-block;
  padding: var(--space-md) var(--space-xl);
  background: var(--color-bg-glass);
  backdrop-filter: blur(20px);
  border: 1px solid var(--color-accent-cyan);
  border-radius: var(--radius-lg);
  color: var(--color-accent-cyan);
  font-weight: 600;
  font-size: 1.1rem;
  transition: all var(--transition-base);
  box-shadow: var(--shadow-glow);
}

.hero-cta:hover {
  background: var(--color-accent-cyan);
  color: var(--color-bg-primary);
  transform: translateY(-2px);
  box-shadow: 0 0 30px rgba(0, 242, 255, 0.6);
}

/* ============================================
   MAIN CONTENT
   ============================================ */

main {
  max-width: 1400px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space-lg);
  width: 100%;
}

.content-section {
  margin-bottom: var(--space-xxl);
  padding: var(--space-xl) 0;
  max-width: 1400px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
}

.section-title {
  text-align: center;
  margin-bottom: var(--space-xl);
  position: relative;
  padding-bottom: var(--space-md);
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-lg);
  padding-right: var(--space-lg);
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 3px;
  background: linear-gradient(90deg, var(--color-accent-cyan), var(--color-accent-purple));
  border-radius: 2px;
}

.section-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-lg);
  margin-top: var(--space-xl);
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 var(--space-lg);
}

.content-card {
  background: var(--color-bg-glass);
  backdrop-filter: blur(20px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.content-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(0, 242, 255, 0.1),
    transparent
  );
  transition: left 0.5s ease;
}

.content-card:hover::before {
  left: 100%;
}

.content-card:hover {
  transform: translateY(-5px);
  border-color: var(--color-accent-cyan);
  box-shadow: var(--shadow-glow);
}

.card-image {
  width: 100%;
  max-width: 300px;
  height: 200px;
  object-fit: cover;
  border-radius: var(--radius-md);
  margin-bottom: var(--space-md);
  border: 1px solid var(--color-border);
}

.card-title {
  font-size: 1.5rem;
  margin-bottom: var(--space-md);
  color: var(--color-accent-cyan);
}

.card-text {
  color: var(--color-text-secondary);
  line-height: 1.7;
}

/* ============================================
   TWO COLUMN LAYOUT
   ============================================ */

.two-column {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  align-items: center;
  margin-top: var(--space-xl);
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 var(--space-lg);
}

.two-column-image {
  width: 100%;
  height: 400px;
  object-fit: cover;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);
}

.two-column-content {
  padding: var(--space-lg);
}

/* ============================================
   PRODUCTS GRID
   ============================================ */

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-lg);
  margin-top: var(--space-xl);
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 var(--space-lg);
}

.product-card {
  background: var(--color-bg-glass);
  backdrop-filter: blur(20px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  text-align: center;
  transition: all var(--transition-base);
}

.product-card:hover {
  transform: translateY(-8px);
  border-color: var(--color-accent-purple);
  box-shadow: var(--shadow-purple);
}

.product-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: var(--radius-md);
  margin-bottom: var(--space-lg);
  border: 1px solid var(--color-border);
}

.product-title {
  font-size: 1.5rem;
  margin-bottom: var(--space-md);
  color: var(--color-accent-cyan);
}

.product-price {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--color-accent-purple);
  margin: var(--space-md) 0;
}

/* ============================================
   CONTACT FORM
   ============================================ */

.contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  margin-top: var(--space-xl);
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 var(--space-lg);
}

.contact-form {
  background: var(--color-bg-glass);
  backdrop-filter: blur(20px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
}

.form-group {
  margin-bottom: var(--space-lg);
}

.form-label {
  display: block;
  margin-bottom: var(--space-sm);
  color: var(--color-text-primary);
  font-weight: 500;
}

.form-input,
.form-textarea {
  width: 100%;
  padding: var(--space-md);
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  color: var(--color-text-primary);
  font-family: var(--font-primary);
  font-size: 1rem;
  transition: all var(--transition-base);
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--color-accent-cyan);
  box-shadow: 0 0 0 3px rgba(0, 242, 255, 0.1);
}

.form-textarea {
  min-height: 150px;
  resize: vertical;
}

.checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  margin: var(--space-lg) 0;
}

.checkbox-input {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  cursor: pointer;
  accent-color: var(--color-accent-cyan);
}

.checkbox-label {
  color: var(--color-text-secondary);
  font-size: 0.9rem;
  line-height: 1.5;
}

.submit-button {
  width: 100%;
  padding: var(--space-md) var(--space-xl);
  background: linear-gradient(135deg, var(--color-accent-cyan), var(--color-accent-purple));
  border: none;
  border-radius: var(--radius-lg);
  color: var(--color-bg-primary);
  font-weight: 700;
  font-size: 1.1rem;
  cursor: pointer;
  transition: all var(--transition-base);
  box-shadow: var(--shadow-glow);
  margin-top: 10px;
}

.submit-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 30px rgba(0, 242, 255, 0.6);
}

.contact-info {
  background: var(--color-bg-glass);
  backdrop-filter: blur(20px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
}

.info-item {
  margin-bottom: var(--space-lg);
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid var(--color-border);
}

.info-item:last-child {
  border-bottom: none;
}

.info-label {
  color: var(--color-accent-cyan);
  font-weight: 600;
  margin-bottom: var(--space-sm);
}

.info-value {
  color: var(--color-text-secondary);
}

.map-container {
  margin-top: var(--space-xl);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--color-border);
  height: 400px;
}

.map-container iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* ============================================
   FOOTER
   ============================================ */

.footer-container {
  background: var(--color-bg-secondary);
  border-top: 1px solid var(--color-border);
  padding: var(--space-xl) var(--space-lg);
  margin-top: var(--space-xxl);
}

.footer-wrapper {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-xl);
}

.footer-section {
  margin-bottom: var(--space-lg);
}

.footer-title {
  font-size: 1.1rem;
  margin-bottom: var(--space-md);
  color: var(--color-accent-cyan);
}

.footer-menu {
  list-style: none;
}

.footer-link {
  display: block;
  padding: var(--space-sm) 0;
  color: var(--color-text-secondary);
  transition: color var(--transition-fast);
}

.footer-link:hover {
  color: var(--color-accent-cyan);
  padding-left: var(--space-sm);
}

.footer-text {
  color: var(--color-text-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
}

.footer-bottom {
  text-align: center;
  padding-top: var(--space-lg);
  margin-top: var(--space-lg);
  border-top: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  font-size: 0.85rem;
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.text-center {
  text-align: center;
}

.mt-sm { margin-top: var(--space-sm); }
.mt-md { margin-top: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }
.mt-xl { margin-top: var(--space-xl); }

.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }
.mb-xl { margin-bottom: var(--space-xl); }

/* ============================================
   PRIVACY POPUP
   ============================================ */

.privacy-popup {
  display: none;
  position: fixed;
  bottom: var(--space-lg);
  left: var(--space-lg);
  right: var(--space-lg);
  max-width: 500px;
  background: var(--color-bg-glass);
  backdrop-filter: blur(30px);
  border: 1px solid var(--color-accent-cyan);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  z-index: 10000;
  box-shadow: var(--shadow-lg);
}

.privacy-popup.active {
  display: block;
  animation: slideUp 0.5s ease;
}

@keyframes slideUp {
  from {
    transform: translateY(100px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.privacy-popup-content {
  margin-bottom: var(--space-lg);
}

.privacy-popup-buttons {
  display: flex;
  gap: var(--space-md);
}

.privacy-button {
  flex: 1;
  padding: var(--space-md);
  border: none;
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-base);
}

.privacy-accept {
  background: var(--color-accent-cyan);
  color: var(--color-bg-primary);
}

.privacy-accept:hover {
  background: var(--color-accent-purple);
}

.privacy-decline {
  background: transparent;
  border: 1px solid var(--color-border);
  color: var(--color-text-primary);
}

.privacy-decline:hover {
  border-color: var(--color-accent-cyan);
  color: var(--color-accent-cyan);
}

/* ============================================
   THANK YOU PAGE
   ============================================ */

.thank-you-container {
  text-align: center;
  padding: var(--space-xxl) var(--space-lg);
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.thank-you-icon {
  font-size: 4rem;
  color: var(--color-accent-cyan);
  margin-bottom: var(--space-lg);
}

.thank-you-title {
  font-size: clamp(2rem, 5vw, 3rem);
  margin-bottom: var(--space-lg);
}

.thank-you-message {
  max-width: 600px;
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--color-text-secondary);
}

/* ============================================
   ERROR 404 PAGE
   ============================================ */

.error-container {
  text-align: center;
  padding: var(--space-xxl) var(--space-lg);
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.error-code {
  font-size: clamp(4rem, 10vw, 8rem);
  font-weight: 700;
  background: linear-gradient(135deg, var(--color-accent-cyan), var(--color-accent-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: var(--space-lg);
}

.error-message {
  font-size: clamp(1.25rem, 3vw, 1.75rem);
  margin-bottom: var(--space-lg);
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 1023px) {
  .nav-menu {
    display: none;
  }
  
  .burger-toggle {
    display: flex;
    position: absolute;
    right: var(--space-lg);
    top: 50%;
    transform: translateY(-50%);
  }
  
  .mobile-nav,
  .mobile-nav-overlay {
    display: block;
  }
  
  .header-wrapper {
    padding-right: 60px;
  }
  
  .two-column {
    grid-template-columns: 1fr;
  }
  
  .contact-wrapper {
    grid-template-columns: 1fr;
  }
  
  .hero-banner {
    min-height: 50vh;
  }
  
  .privacy-popup {
    left: var(--space-md);
    right: var(--space-md);
  }
}

@media (max-width: 768px) {
  :root {
    --space-xl: 2rem;
    --space-xxl: 3rem;
  }
  
  .header-container {
    padding: var(--space-md);
  }
  
  main {
    padding: var(--space-lg) var(--space-md);
  }
  
  .content-section {
    margin-bottom: var(--space-xl);
    padding: var(--space-lg) 0;
  }
  
  .section-content {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }
  
  .products-grid {
    grid-template-columns: 1fr;
  }
  
  .hero-content {
    padding: var(--space-lg) var(--space-md);
  }
}

@media (max-width: 480px) {
  html {
    font-size: 14px;
  }
  
  .header-wrapper {
    padding: 0;
  }
  
  .brand-text {
    font-size: 1rem;
  }
  
  .content-card,
  .product-card,
  .contact-form,
  .contact-info {
    padding: var(--space-lg);
  }
  
  .hero-banner {
    min-height: 40vh;
  }
}

@media (max-width: 320px) {
  html {
    font-size: 12px;
  }
  
  .header-container {
    padding: var(--space-sm);
  }
  
  main {
    padding: var(--space-md) var(--space-sm);
  }
}

