/* ==========================================================================
   RIGEOPS - SOBER & CLEAN DESIGN SYSTEM (Railway Inspired)
   B2B Artificial Intelligence & Operations Automation
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Newsreader:opsz,wght@6..72,400;6..72,500;6..72,600&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  /* Color Palette - Flat & Sober */
  --bg-primary: #0d0f14;
  --bg-secondary: #13151c;
  --bg-tertiary: #191b24;
  --bg-card: #15171e;
  --bg-card-hover: #1c1e28;
  
  /* Accents */
  --accent-primary: #5e43ce; /* Railway-like purple */
  --accent-primary-hover: #6f55db;
  --accent-muted: #2d3748;
  --accent-green: #10b981;
  --accent-blue: #3b82f6;
  
  /* Text Colors */
  --text-primary: #f9fafb;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;
  
  /* Borders */
  --border-subtle: rgba(255, 255, 255, 0.06);
  --border-hover: rgba(255, 255, 255, 0.12);
  
  /* Typography */
  --font-serif: 'Newsreader', serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  
  /* Layout */
  --max-width: 1100px;
  --nav-height: 72px;
  
  /* Transitions */
  --transition-fast: 0.15s ease-out;
}

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

html {
  scroll-behavior: smooth;
  color-scheme: dark;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Optional subtle background illustration (like clouds/noise), kept extremely minimal */
body::before {
  content: '';
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background-image: url('data:image/svg+xml;utf8,%3Csvg viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg"%3E%3Cfilter id="noiseFilter"%3E%3CfeTurbulence type="fractalNoise" baseFrequency="0.65" numOctaves="3" stitchTiles="stitch"/%3E%3C/filter%3E%3Crect width="100%25" height="100%25" filter="url(%23noiseFilter)" opacity="0.015"/%3E%3C/svg%3E');
  pointer-events: none;
  z-index: 0;
}

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

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
  position: relative;
  z-index: 1;
}

/* --- Typography --- */
h1, h2, h3 {
  font-family: var(--font-serif);
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: -0.01em;
  line-height: 1.15;
}

h4, h5, h6 {
  font-weight: 600;
}

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

.section-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 3.5rem auto;
}

.section-title {
  font-size: 2.8rem;
  margin-bottom: 1rem;
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-weight: 400;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  border-radius: 6px;
  font-weight: 500;
  font-size: 0.95rem;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all var(--transition-fast);
  text-decoration: none;
}

.btn-primary {
  background-color: var(--accent-primary);
  color: #ffffff;
}

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

.btn-secondary {
  background-color: var(--bg-tertiary);
  color: var(--text-primary);
  border-color: var(--border-subtle);
}

.btn-secondary:hover {
  background-color: var(--bg-card-hover);
  border-color: var(--border-hover);
}

.btn-whatsapp {
  background-color: #25D366; /* WhatsApp brand color */
  color: #000;
  font-weight: 600;
}
.btn-whatsapp:hover {
  background-color: #20bd5a;
}

.btn-lg {
  padding: 0.85rem 1.5rem;
  font-size: 1rem;
}

/* --- Header / Nav --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--nav-height);
  background: var(--bg-primary);
  border-bottom: 1px solid var(--border-subtle);
  z-index: 100;
  display: flex;
  align-items: center;
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 600;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo svg {
  width: 24px;
  height: 24px;
}

.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.nav-links a:hover {
  color: var(--text-primary);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
}

/* --- Hero Section --- */
.hero-section {
  padding-top: calc(var(--nav-height) + 6rem);
  padding-bottom: 5rem;
  text-align: center;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero-title {
  font-size: 4rem;
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.hero-description {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 2.5rem auto;
}

.hero-ctas {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 4rem;
}

/* --- Architecture/Diagram Preview Section --- */
.architecture-preview {
  margin: 0 auto;
  width: 100%;
  max-width: 960px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  overflow: hidden;
}

.arch-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1.25rem;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-primary);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.arch-header-left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.arch-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #374151;
}

.arch-canvas-container {
  position: relative;
  width: 100%;
  height: 400px;
  background: var(--bg-secondary);
}

/* SVG Diagram Styles */
.svg-diagram {
  width: 100%;
  height: 100%;
}

.node-group {
  cursor: pointer;
}

.node-rect {
  fill: var(--bg-primary);
  stroke: var(--border-subtle);
  stroke-width: 1;
  rx: 6; /* rounded corners */
}

.node-group:hover .node-rect {
  stroke: var(--text-muted);
}

.node-title {
  fill: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 500;
}

.node-subtitle {
  fill: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 9px;
}

.node-icon-bg {
  fill: var(--bg-tertiary);
  rx: 4;
}

.conn-line {
  stroke: var(--border-subtle);
  stroke-width: 1.5;
  fill: none;
}

/* Status Indicator in Header */
.status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.status-indicator .dot {
  width: 6px; height: 6px;
  background-color: var(--accent-green);
  border-radius: 50%;
}

/* --- Section: Services / Solutions --- */
.services-section {
  padding: 6rem 0;
  border-top: 1px solid var(--border-subtle);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.service-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 2rem;
  display: flex;
  flex-direction: column;
}

.service-icon {
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.service-title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  font-family: var(--font-sans);
}

.service-desc {
  font-size: 0.95rem;
  margin-bottom: 2rem;
  flex-grow: 1;
}

.service-features {
  list-style: none;
  border-top: 1px solid var(--border-subtle);
  padding-top: 1rem;
  margin-bottom: 1.5rem;
}

.service-features li {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.service-features li::before {
  content: "→";
  color: var(--text-muted);
  font-family: var(--font-mono);
}

/* --- Section: ROI Calculator --- */
.roi-section {
  padding: 6rem 0;
  border-top: 1px solid var(--border-subtle);
}

.roi-container {
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 3rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.roi-title {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.slider-group {
  margin-bottom: 2rem;
}

.slider-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
}
.slider-val {
  font-family: var(--font-mono);
  color: var(--text-primary);
}

input[type="range"] {
  -webkit-appearance: none;
  width: 100%;
  height: 4px;
  background: var(--bg-tertiary);
  border-radius: 2px;
  outline: none;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  background: var(--text-primary);
  border-radius: 50%;
  cursor: pointer;
}

.roi-result {
  background: var(--bg-primary);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 2rem;
  text-align: center;
}

.roi-number {
  font-size: 3rem;
  font-family: var(--font-serif);
  color: var(--text-primary);
  line-height: 1;
  margin: 1rem 0;
}

.roi-sub {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
}

/* --- Section: FAQ --- */
.faq-section {
  padding: 6rem 0;
  border-top: 1px solid var(--border-subtle);
}

.faq-list {
  max-width: 700px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid var(--border-subtle);
}
.faq-item:last-child {
  border-bottom: none;
}

.faq-q {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  padding: 1.5rem 0;
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq-a {
  max-height: 0;
  overflow: hidden;
  color: var(--text-secondary);
  font-size: 0.95rem;
  transition: max-height 0.3s ease;
}

.faq-item.active .faq-a {
  max-height: 300px;
  padding-bottom: 1.5rem;
}

/* --- Section: Contact (Meta Validation) --- */
.contact-section {
  padding: 6rem 0;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-secondary);
  text-align: center;
}

.contact-card {
  max-width: 600px;
  margin: 0 auto;
}

.contact-card h2 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2.5rem;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.contact-info strong {
  color: var(--text-primary);
  font-weight: 500;
}

/* --- Footer --- */
.legal-footer {
  padding: 2rem 0;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-primary);
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* --- Responsive --- */
@media (max-width: 900px) {
  .hero-title { font-size: 3rem; }
  .services-grid { grid-template-columns: 1fr; }
  .roi-container { grid-template-columns: 1fr; gap: 2rem; }
}

@media (max-width: 600px) {
  .nav-links, .nav-actions .btn { display: none; }
  .mobile-toggle { display: block; }
  .hero-title { font-size: 2.2rem; }
  .hero-ctas { flex-direction: column; }
}
