/* ============================================
   Peak Clean Co. - Main Stylesheet
   ============================================ */

/* ============================================
   CSS Custom Properties (Design Tokens)
   ============================================ */
:root {
  /* Color Palette - Cyan/Teal with deep surfaces */
  --surface-0: #05070C;
  --surface-1: #0A0D12;
  --surface-2: #0F131C;
  --surface-3: #161D2B;
  --surface-4: #1E2636;
  
  --accent-primary: #38BDF8;
  --accent-secondary: #6EE7B7;
  --accent-muted: #1E3A5F;
  
  --text-primary: rgba(255, 255, 255, 0.95);
  --text-secondary: rgba(255, 255, 255, 0.75);
  --text-tertiary: rgba(255, 255, 255, 0.5);
  
  /* Typography */
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: var(--font-body);
  
  /* Fluid Typography Scale */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.375vw, 1rem);
  --text-base: clamp(1rem, 0.925rem + 0.375vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.625vw, 1.375rem);
  --text-xl: clamp(1.25rem, 1.1rem + 0.75vw, 1.625rem);
  --text-2xl: clamp(1.5rem, 1.25rem + 1.25vw, 2.25rem);
  --text-3xl: clamp(2rem, 1.5rem + 2.5vw, 3.5rem);
  --text-4xl: clamp(2.5rem, 1.75rem + 3.75vw, 4.5rem);
  
  /* Spacing Scale */
  --space-xs: clamp(0.5rem, 0.45rem + 0.25vw, 0.625rem);
  --space-sm: clamp(0.75rem, 0.65rem + 0.5vw, 1rem);
  --space-md: clamp(1rem, 0.85rem + 0.75vw, 1.5rem);
  --space-lg: clamp(1.5rem, 1.2rem + 1.5vw, 2.5rem);
  --space-xl: clamp(2rem, 1.5rem + 2.5vw, 4rem);
  --space-2xl: clamp(3rem, 2rem + 5vw, 6rem);
  
  /* Border Radius */
  --radius-sm: 0.5rem;
  --radius-md: 1rem;
  --radius-lg: 1.5rem;
  --radius-pill: 999px;
  --radius-circle: 50%;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.25);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.4);
  --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.5);
  
  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 400ms ease;
}

/* ============================================
   Base & Reset
   ============================================ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--surface-0);
  min-height: 100vh;
}

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

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

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

/* ============================================
   Typography
   ============================================ */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

h1 {
  font-size: var(--text-4xl);
  letter-spacing: -0.03em;
}

h2 {
  font-size: var(--text-3xl);
}

h3 {
  font-size: var(--text-2xl);
}

h4 {
  font-size: var(--text-xl);
}

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

/* ============================================
   Layout Containers
   ============================================ */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--space-md);
}

.container-narrow {
  max-width: 960px;
}

.container-wide {
  max-width: 1440px;
}

/* ============================================
   Navigation
   ============================================ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--surface-1);
  border-bottom: 1px solid var(--surface-3);
  backdrop-filter: blur(12px);
  transition: transform var(--transition-base);
}

.nav.scrolled {
  box-shadow: var(--shadow-md);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}

.logo img {
  height: 48px;
  width: auto;
}

.nav-links {
  display: flex;
  gap: var(--space-lg);
  list-style: none;
}

.nav-links a {
  color: var(--text-secondary);
  font-weight: 500;
  font-size: var(--text-sm);
  transition: color var(--transition-fast);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent-primary);
}

.nav-cta {
  display: flex;
  gap: var(--space-sm);
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
  padding: var(--space-xs);
}

/* Mobile Navigation */
@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--surface-2);
    padding: var(--space-lg);
    gap: var(--space-md);
    transform: translateX(-100%);
    transition: transform var(--transition-base);
    box-shadow: var(--shadow-lg);
  }
  
  .nav-links.active {
    transform: translateX(0);
  }
  
  .menu-toggle {
    display: block;
  }
  
  .nav-cta {
    display: none;
  }
}

/* ============================================
   Buttons
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: 0.875rem 1.75rem;
  font-size: var(--text-base);
  font-weight: 600;
  border: none;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: all var(--transition-base);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent-primary);
  color: var(--surface-0);
}

.btn-primary:hover {
  background: var(--accent-secondary);
  color: var(--surface-0);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-secondary {
  background: var(--surface-3);
  color: var(--text-primary);
  border: 1px solid var(--surface-4);
}

.btn-secondary:hover {
  background: var(--surface-4);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
}

.btn-outline {
  background: transparent;
  color: var(--accent-primary);
  border: 2px solid var(--accent-primary);
}

.btn-outline:hover {
  background: var(--accent-primary);
  color: var(--surface-0);
}

.btn-lg {
  padding: 1.125rem 2.25rem;
  font-size: var(--text-lg);
}

.btn-sm {
  padding: 0.625rem 1.25rem;
  font-size: var(--text-sm);
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
  min-height: 100svh;
  min-height: 560px;
  display: grid;
  align-items: center;
  background: linear-gradient(135deg, var(--surface-1) 0%, var(--surface-2) 100%);
  position: relative;
  overflow: hidden;
  padding-top: 80px;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    radial-gradient(circle at 20% 20%, rgba(56, 189, 248, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(110, 231, 183, 0.1) 0%, transparent 50%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  padding: 90px 24px 40px;
  max-width: 800px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: 0.5rem 1rem;
  background: var(--accent-muted);
  color: var(--accent-primary);
  border-radius: var(--radius-pill);
  font-size: var(--text-sm);
  font-weight: 600;
  margin-bottom: var(--space-md);
  border: 1px solid rgba(56, 189, 248, 0.2);
}

.hero h1 {
  margin-bottom: var(--space-md);
  color: var(--text-primary);
}

.hero-subtitle {
  font-size: var(--text-lg);
  color: var(--text-secondary);
  margin-bottom: var(--space-xl);
  max-width: 600px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md);
}

@media (max-width: 768px) {
  .hero-content {
    padding: 70px 20px 30px;
  }
  
  .hero-badge {
    font-size: var(--text-xs);
    padding: 0.4rem 0.875rem;
    margin-bottom: var(--space-sm);
  }
  
  .hero h1 {
    margin-bottom: var(--space-sm);
  }
  
  .hero-subtitle {
    margin-bottom: var(--space-lg);
  }
  
  .hero-actions {
    flex-direction: column;
  }
  
  .hero-actions .btn {
    width: 100%;
    justify-content: center;
    padding: 1rem 1.5rem;
  }
}

/* ============================================
   Sections
   ============================================ */
section {
  padding: var(--space-2xl) 0;
}

.section-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto var(--space-xl);
}

.section-badge {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: var(--surface-2);
  color: var(--accent-primary);
  border-radius: var(--radius-pill);
  font-size: var(--text-sm);
  font-weight: 600;
  margin-bottom: var(--space-md);
  border: 1px solid var(--surface-3);
}

.section-title {
  margin-bottom: var(--space-md);
}

.section-description {
  font-size: var(--text-lg);
  color: var(--text-secondary);
}

/* ============================================
   Grid Layouts
   ============================================ */
.grid {
  display: grid;
  gap: var(--space-lg);
}

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

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

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

@media (max-width: 768px) {
  .grid {
    gap: var(--space-md);
  }
  
  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }
}

/* ============================================
   Cards
   ============================================ */
.card {
  background: var(--surface-2);
  border: 1px solid var(--surface-3);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  transition: all var(--transition-base);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent-primary);
}

.card-icon {
  width: 48px;
  height: 48px;
  background: var(--accent-muted);
  border-radius: var(--radius-circle);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-primary);
  margin-bottom: var(--space-md);
}

.card-icon i {
  width: 24px;
  height: 24px;
}

.card-title {
  font-size: var(--text-xl);
  margin-bottom: var(--space-sm);
  color: var(--text-primary);
}

.card-description {
  color: var(--text-secondary);
  margin-bottom: var(--space-md);
}

.card-link {
  color: var(--accent-primary);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  transition: gap var(--transition-fast);
}

.card-link:hover {
  gap: var(--space-sm);
}

/* ============================================
   Offer Section
   ============================================ */
.offer-section {
  background: linear-gradient(135deg, var(--accent-muted) 0%, var(--surface-2) 100%);
  border: 2px solid var(--accent-primary);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.offer-section::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.1) 0%, transparent 70%);
  pointer-events: none;
}

.offer-content {
  position: relative;
  z-index: 1;
}

.offer-badge {
  display: inline-block;
  background: var(--accent-primary);
  color: var(--surface-0);
  padding: 0.625rem 1.5rem;
  border-radius: var(--radius-pill);
  font-size: var(--text-lg);
  font-weight: 700;
  margin-bottom: var(--space-md);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.offer-title {
  font-size: var(--text-3xl);
  margin-bottom: var(--space-sm);
  color: var(--accent-primary);
}

.offer-description {
  font-size: var(--text-lg);
  color: var(--text-secondary);
  margin-bottom: var(--space-md);
}

.offer-terms {
  font-size: var(--text-sm);
  color: var(--text-tertiary);
  font-style: italic;
}

/* ============================================
   Feature List
   ============================================ */
.feature-list {
  display: grid;
  gap: var(--space-md);
}

.feature-item {
  display: flex;
  gap: var(--space-md);
  align-items: flex-start;
}

.feature-icon {
  width: 40px;
  height: 40px;
  background: var(--accent-muted);
  border-radius: var(--radius-circle);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-primary);
  flex-shrink: 0;
}

.feature-icon i {
  width: 20px;
  height: 20px;
}

.feature-content h4 {
  margin-bottom: var(--space-xs);
  color: var(--text-primary);
}

.feature-content p {
  color: var(--text-secondary);
}

/* ============================================
   Forms
   ============================================ */
.form-group {
  margin-bottom: var(--space-md);
}

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

.form-label .required {
  color: var(--accent-primary);
  margin-left: 0.25rem;
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  padding: 0.875rem 1rem;
  background: var(--surface-3);
  border: 1px solid var(--surface-4);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: var(--text-base);
  font-family: var(--font-body);
  transition: all var(--transition-fast);
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.1);
}

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

.form-error {
  color: #ff6b6b;
  font-size: var(--text-sm);
  margin-top: var(--space-xs);
}

.form-success {
  padding: var(--space-md);
  background: rgba(110, 231, 183, 0.1);
  border: 1px solid var(--accent-secondary);
  border-radius: var(--radius-sm);
  color: var(--accent-secondary);
  text-align: center;
  margin-bottom: var(--space-md);
}

/* ============================================
   Footer
   ============================================ */
.footer {
  background: var(--surface-1);
  border-top: 1px solid var(--surface-3);
  padding: var(--space-2xl) 0 var(--space-lg);
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--space-xl);
  margin-bottom: var(--space-xl);
}

.footer-section h4 {
  color: var(--text-primary);
  margin-bottom: var(--space-md);
  font-size: var(--text-lg);
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.footer-links a {
  color: var(--text-secondary);
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--accent-primary);
}

.footer-social {
  display: flex;
  gap: var(--space-md);
  margin-top: var(--space-md);
}

.social-icon {
  width: 40px;
  height: 40px;
  background: var(--surface-3);
  border-radius: var(--radius-circle);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: all var(--transition-fast);
}

.social-icon:hover {
  background: var(--accent-primary);
  color: var(--surface-0);
  transform: translateY(-2px);
}

.social-icon i {
  width: 20px;
  height: 20px;
}

.footer-bottom {
  padding-top: var(--space-lg);
  border-top: 1px solid var(--surface-3);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-md);
  font-size: var(--text-sm);
  color: var(--text-tertiary);
}

.footer-bottom a {
  color: var(--text-secondary);
}

.footer-bottom a:hover {
  color: var(--accent-primary);
}

@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }
  
  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }
}

/* ============================================
   Utility Classes
   ============================================ */
.text-center {
  text-align: center;
}

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

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

.mt-0 { margin-top: 0; }
.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-0 { margin-bottom: 0; }
.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); }

.hidden {
  display: none;
}

/* ============================================
   Animations
   ============================================ */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn var(--transition-slow) ease-out;
}

/* ============================================
   Loading State
   ============================================ */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid var(--surface-4);
  border-top-color: var(--accent-primary);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}
