/* Catto Consulting - Premium Brand Styles */

:root {
  /* Colors */
  --color-charcoal: #1a1a1a;
  --color-warm-gray: #6b6563;
  --color-light-gray: #a8a5a3;
  --color-off-white: #faf9f8;
  --color-cream: #f5f3f0;
  --color-terracotta: #c4654a;
  --color-terracotta-hover: #d4735a;
  --color-terracotta-glow: rgba(196, 101, 74, 0.15);

  /* Dark mode colors */
  --color-near-black: #0a0a0a;
  --color-dark-surface: #141414;
  --color-warm-white: #f5f4f3;

  /* Typography */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-display: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', monospace;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 2rem;
  --space-xl: 4rem;
  --space-2xl: 6rem;
  --space-3xl: 10rem;

  /* Layout */
  --max-width: 1400px;
  --content-width: 720px;

  /* Animation */
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1);
  --duration-fast: 0.2s;
  --duration-medium: 0.4s;
  --duration-slow: 0.8s;
}

/* Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Smooth scroll */
html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--color-charcoal);
  background-color: var(--color-off-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* Selection */
::selection {
  background: var(--color-terracotta);
  color: white;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.15;
  color: var(--color-charcoal);
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2.75rem, 7vw, 5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
}

h2 {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 600;
}

h3 {
  font-size: 1.375rem;
  font-weight: 500;
}

p {
  color: var(--color-warm-gray);
}

a {
  color: var(--color-terracotta);
  text-decoration: none;
  transition: color var(--duration-fast) ease;
}

a:hover {
  color: var(--color-terracotta-hover);
}

/* Layout */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

/* ============================================
   NAVIGATION
   ============================================ */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: var(--space-md) var(--space-lg);
  transition: all var(--duration-medium) var(--ease-out-expo);
}

nav.scrolled {
  background: rgba(250, 249, 248, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

nav .nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

nav .logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--color-charcoal);
  letter-spacing: -0.02em;
  transition: opacity var(--duration-fast) ease;
}

nav .logo:hover {
  opacity: 0.7;
}

nav ul {
  display: flex;
  gap: var(--space-xl);
  list-style: none;
}

nav a {
  color: var(--color-warm-gray);
  font-size: 0.9375rem;
  font-weight: 450;
  position: relative;
  padding: var(--space-xs) 0;
}

nav a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--color-terracotta);
  transition: width var(--duration-medium) var(--ease-out-expo);
}

nav a:hover {
  color: var(--color-charcoal);
}

nav a:hover::after {
  width: 100%;
}

/* ============================================
   HERO
   ============================================ */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--space-3xl) 0;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 80%;
  height: 150%;
  background: radial-gradient(ellipse at center, var(--color-terracotta-glow) 0%, transparent 70%);
  pointer-events: none;
  opacity: 0.6;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
}

.hero h1 {
  margin-bottom: var(--space-lg);
  opacity: 0;
  transform: translateY(40px);
  animation: fadeUp 1s var(--ease-out-expo) 0.2s forwards;
}

.hero h1 .accent {
  color: var(--color-terracotta);
}

.hero .subtitle {
  font-size: clamp(1.125rem, 2vw, 1.375rem);
  max-width: 600px;
  margin-bottom: var(--space-xl);
  opacity: 0;
  transform: translateY(30px);
  animation: fadeUp 1s var(--ease-out-expo) 0.4s forwards;
}

.hero .btn-group {
  display: flex;
  gap: var(--space-md);
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp 1s var(--ease-out-expo) 0.6s forwards;
}

/* Cat silhouette */
.cat-silhouette {
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  z-index: 10;
  line-height: 0;
  pointer-events: none;
}

.cat-silhouette svg {
  width: 100%;
  height: clamp(100px, 15vw, 200px);
  fill: var(--color-terracotta);
}

/* Scroll indicator */
.scroll-indicator {
  position: absolute;
  bottom: var(--space-xl);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  opacity: 0;
  animation: fadeIn 1s var(--ease-out-expo) 1.2s forwards;
}

.scroll-indicator span {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-light-gray);
}

.scroll-indicator .line {
  width: 1px;
  height: 60px;
  background: linear-gradient(to bottom, var(--color-terracotta), transparent);
  animation: scrollLine 2s ease-in-out infinite;
}

@keyframes scrollLine {
  0%, 100% { transform: scaleY(0); transform-origin: top; }
  50% { transform: scaleY(1); transform-origin: top; }
  51% { transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 1rem 2rem;
  font-size: 0.9375rem;
  font-weight: 500;
  border-radius: 100px;
  transition: all var(--duration-medium) var(--ease-out-expo);
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--color-charcoal);
  color: var(--color-off-white);
}

.btn-primary:hover {
  background: var(--color-terracotta);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 10px 40px var(--color-terracotta-glow);
}

.btn-secondary {
  background: transparent;
  color: var(--color-charcoal);
  border: 1px solid rgba(0, 0, 0, 0.15);
}

.btn-secondary:hover {
  border-color: var(--color-charcoal);
  transform: translateY(-2px);
}

.btn .arrow {
  transition: transform var(--duration-fast) ease;
}

.btn:hover .arrow {
  transform: translateX(4px);
}

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

.section-header {
  margin-bottom: var(--space-2xl);
}

.section-header .label {
  display: inline-block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--color-terracotta);
  font-weight: 500;
  margin-bottom: var(--space-md);
}

.section-header h2 {
  max-width: 600px;
}

/* ============================================
   SERVICES
   ============================================ */
.services {
  background: var(--color-off-white);
  padding-top: calc(var(--space-3xl) + 100px);
  position: relative;
}

.services::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 50%;
  height: 100%;
  background: var(--color-terracotta);
  z-index: 0;
}

.services > .container {
  position: relative;
  z-index: 1;
}

.services .section-header {
  position: relative;
  z-index: 1;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-md);
  position: relative;
  z-index: 1;
}

.service-card {
  padding: var(--space-xl);
  background: var(--color-off-white);
  border-radius: 16px;
  transition: all var(--duration-medium) var(--ease-out-expo);
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--color-terracotta);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--duration-medium) var(--ease-out-expo);
}

.service-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.12);
}

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

.service-card .number {
  font-size: 0.75rem;
  color: var(--color-light-gray);
  font-weight: 500;
  margin-bottom: var(--space-lg);
}

.service-card h3 {
  margin-bottom: var(--space-md);
}

.service-card p {
  font-size: 1rem;
  line-height: 1.6;
}

/* ============================================
   FEATURED WORK
   ============================================ */
.work-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-lg);
}

.work-card {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  aspect-ratio: 4/3;
  cursor: pointer;
}

.work-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--duration-slow) var(--ease-out-expo);
}

.work-card:hover img {
  transform: scale(1.05);
}

.work-card .overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 60%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--space-xl);
  transition: all var(--duration-medium) var(--ease-out-expo);
}

.work-card:hover .overlay {
  background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.2) 100%);
}

.work-card .tag {
  display: inline-block;
  padding: 0.375rem 0.875rem;
  background: var(--color-terracotta);
  color: white;
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: 100px;
  margin-bottom: var(--space-md);
  width: fit-content;
}

.work-card h3 {
  color: white;
  font-size: 1.5rem;
  margin-bottom: var(--space-sm);
}

.work-card p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 1rem;
  margin-bottom: var(--space-md);
}

.work-card .link {
  color: white;
  font-size: 0.875rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  opacity: 0;
  transform: translateY(10px);
  transition: all var(--duration-medium) var(--ease-out-expo);
}

.work-card:hover .link {
  opacity: 1;
  transform: translateY(0);
}

.work-card .link .arrow {
  transition: transform var(--duration-fast) ease;
}

.work-card:hover .link .arrow {
  transform: translateX(4px);
}

/* ============================================
   BLOG / INSIGHTS
   ============================================ */
.insights {
  background: var(--color-charcoal);
  color: var(--color-warm-white);
}

.insights .section-header h2 {
  color: var(--color-warm-white);
}

.insights-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
}

.insight-card {
  display: flex;
  flex-direction: column;
  padding: var(--space-xl);
  background: var(--color-dark-surface);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: all var(--duration-medium) var(--ease-out-expo);
}

.insight-card:hover {
  border-color: var(--color-terracotta);
  transform: translateY(-4px);
}

.insight-card .meta {
  font-size: 0.8125rem;
  color: var(--color-light-gray);
  margin-bottom: var(--space-md);
  display: flex;
  gap: var(--space-md);
}

.insight-card h3 {
  color: var(--color-warm-white);
  margin-bottom: var(--space-md);
  flex-grow: 1;
}

.insight-card h3 a {
  color: inherit;
}

.insight-card h3 a:hover {
  color: var(--color-terracotta);
}

.insight-card p {
  color: var(--color-light-gray);
  font-size: 1rem;
  line-height: 1.6;
}

/* Featured insight (larger) */
.insight-card.featured {
  grid-column: span 2;
  flex-direction: row;
  gap: var(--space-xl);
  padding: 0;
  overflow: hidden;
}

.insight-card.featured img {
  width: 50%;
  object-fit: cover;
}

.insight-card.featured .content {
  padding: var(--space-xl);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.insight-card.featured h3 {
  font-size: 1.75rem;
}

/* ============================================
   CTA SECTION
   ============================================ */
.cta-section {
  text-align: center;
  padding: var(--space-3xl) 0;
  position: relative;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(ellipse at center, var(--color-terracotta-glow) 0%, transparent 70%);
  pointer-events: none;
}

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

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

.cta-section p {
  font-size: 1.25rem;
  margin-bottom: var(--space-xl);
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

/* ============================================
   FOOTER
   ============================================ */
footer {
  padding: var(--space-2xl) 0;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-left p {
  font-size: 0.875rem;
  color: var(--color-light-gray);
}

.footer-right {
  display: flex;
  gap: var(--space-lg);
}

.footer-right a {
  color: var(--color-warm-gray);
  font-size: 0.875rem;
}

.footer-right a:hover {
  color: var(--color-charcoal);
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Scroll animations */
.reveal {
  opacity: 0;
  transform: translateY(60px);
  transition: all var(--duration-slow) var(--ease-out-expo);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* Stagger children */
.stagger-children .reveal {
  transition-delay: calc(var(--i, 0) * 0.1s);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .services::before {
    width: 100%;
    height: 50%;
    top: auto;
    bottom: 0;
  }

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

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

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

  .insight-card.featured {
    grid-column: span 1;
    flex-direction: column;
  }

  .insight-card.featured img {
    width: 100%;
    height: 200px;
  }
}

@media (max-width: 768px) {
  :root {
    --space-2xl: 4rem;
    --space-3xl: 6rem;
  }

  nav ul {
    display: none;
  }

  .hero {
    min-height: auto;
    padding: 8rem 0 4rem;
  }

  .hero .btn-group {
    flex-direction: column;
  }

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

  .scroll-indicator {
    display: none;
  }

  .footer-inner {
    flex-direction: column;
    gap: var(--space-lg);
    text-align: center;
  }
}

/* ============================================
   DARK MODE
   ============================================ */
@media (prefers-color-scheme: dark) {
  body {
    background-color: var(--color-near-black);
    color: var(--color-warm-white);
  }

  h1, h2, h3, h4, h5, h6 {
    color: var(--color-warm-white);
  }

  nav.scrolled {
    background: rgba(10, 10, 10, 0.8);
    border-bottom-color: rgba(255, 255, 255, 0.05);
  }

  nav .logo,
  nav a:hover {
    color: var(--color-warm-white);
  }

  .btn-primary {
    background: var(--color-warm-white);
    color: var(--color-near-black);
  }

  .btn-primary:hover {
    background: var(--color-terracotta);
    color: white;
  }

  .btn-secondary {
    color: var(--color-warm-white);
    border-color: rgba(255, 255, 255, 0.2);
  }

  .btn-secondary:hover {
    border-color: var(--color-warm-white);
  }

  .services {
    background: var(--color-near-black);
  }

  .services::before {
    background: var(--color-terracotta);
  }

  .service-card {
    background: var(--color-near-black);
    border: 1px solid rgba(255, 255, 255, 0.05);
  }

  .insight-card {
    background: rgba(255, 255, 255, 0.03);
  }

  footer {
    border-top-color: rgba(255, 255, 255, 0.08);
  }

  .footer-right a:hover {
    color: var(--color-warm-white);
  }
}
