/* CQRE.NET — Main Stylesheet v2.0 */
/* Modern cybersecurity aesthetic */

:root {
  --bg-deep: #03070f;
  --bg-primary: #050a14;
  --bg-secondary: #0a1628;
  --bg-tertiary: #0d1f38;
  --bg-elevated: #122440;
  --accent: #fbbf24;
  --accent-dim: #8b5cf6;
  --accent-glow: rgba(251, 191, 36, 0.15);
  --accent-glow-strong: rgba(251, 191, 36, 0.35);
  --orange: #f97316;
  --green: #22c55e;
  --text: #e2e8f0;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --border: rgba(148, 163, 184, 0.08);
  --border-hover: rgba(251, 191, 36, 0.25);
  --card-bg: rgba(10, 22, 40, 0.6);
  --card-hover: rgba(13, 31, 56, 0.8);
  --radius: 10px;
  --radius-lg: 16px;
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --max-width: 1200px;
  --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --font-mono: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
}

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

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

body {
  background: var(--bg-primary);
  color: var(--text);
  font-family: var(--font-sans);
  line-height: 1.7;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
}

/* Subtle grid background */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(139, 92, 246, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(139, 92, 246, 0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(0,0,0,0.4) 0%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(0,0,0,0.4) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

main { position: relative; z-index: 1; }

a { color: var(--accent); text-decoration: none; transition: color var(--transition), filter var(--transition); }
a:hover { color: #fde68a; filter: brightness(1.15); }

/* ── Typography ── */
h1, h2, h3, h4 { line-height: 1.2; font-weight: 700; letter-spacing: -0.02em; }
h1 { font-size: clamp(2.2rem, 5.5vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); }
h3 { font-size: 1.3rem; }
h4 { font-size: 1.1rem; }
p { margin-bottom: 1rem; }
p:last-child { margin-bottom: 0; }
strong { color: #f8fafc; font-weight: 600; }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 1.5rem; }

/* ── Header / Nav ── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(5, 10, 20, 0.85);
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  border-bottom: 1px solid var(--border);
}

.site-header::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, var(--accent) 50%, transparent 100%);
  opacity: 0.4;
}

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

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #f8fafc;
  text-decoration: none;
}

.site-logo img {
  height: 36px;
  width: auto;
  filter: drop-shadow(0 0 8px rgba(251, 191, 36, 0.3));
}

.site-logo span { color: var(--accent); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  list-style: none;
  flex-wrap: wrap;
}

.nav-links a {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.45rem 0.85rem;
  border-radius: var(--radius);
  transition: color var(--transition), background var(--transition), box-shadow var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
  background: rgba(0, 212, 255, 0.08);
  box-shadow: 0 0 16px rgba(251, 191, 36, 0.08);
}

.nav-lang {
  font-size: 0.85rem;
  padding: 0.4rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-muted);
  margin-left: 0.5rem;
  transition: all var(--transition);
  font-family: var(--font-mono);
  font-size: 0.8rem;
}

.nav-lang:hover {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 0 0 12px rgba(251, 191, 36, 0.15);
}

/* Mobile toggle */
.nav-mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  cursor: pointer;
  padding: 0.4rem;
}

.nav-mobile-toggle svg { width: 24px; height: 24px; }

/* ── Hero ── */
.hero {
  padding: 8rem 1.5rem 6rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 50% at 50% 0%, rgba(0, 212, 255, 0.1) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 80% 20%, rgba(14, 165, 233, 0.06) 0%, transparent 50%);
  pointer-events: none;
}

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

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(251, 191, 36, 0.08);
  border: 1px solid rgba(251, 191, 36, 0.2);
  padding: 0.4rem 1rem;
  border-radius: 100px;
  margin-bottom: 1.75rem;
  box-shadow: 0 0 20px rgba(251, 191, 36, 0.08);
}

.hero h1 {
  color: #f8fafc;
  margin-bottom: 1.5rem;
  text-shadow: 0 0 40px rgba(251, 191, 36, 0.1);
}

.hero h1 em { font-style: normal; color: var(--accent); }

.hero-sub {
  font-size: 1.2rem;
  color: var(--text-muted);
  max-width: 640px;
  margin: 0 auto 2.75rem;
  line-height: 1.7;
}

.hero-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.6rem;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
  text-decoration: none;
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, #d97706 100%);
  color: #03070f;
  box-shadow: 0 0 24px rgba(251, 191, 36, 0.25), 0 4px 12px rgba(0, 0, 0, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #fcd34d 0%, #f59e0b 100%);
  color: #03070f;
  box-shadow: 0 0 32px rgba(251, 191, 36, 0.4), 0 6px 16px rgba(0, 0, 0, 0.4);
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.03);
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 0 0 20px rgba(251, 191, 36, 0.1), inset 0 1px 0 rgba(255,255,255,0.06);
  transform: translateY(-1px);
}

.btn-sm { padding: 0.5rem 1rem; font-size: 0.85rem; }

/* ── Sections ── */
.section { padding: 5.5rem 1.5rem; position: relative; }
.section-sm { padding: 3rem 1.5rem; }
.section-alt { background: linear-gradient(180deg, var(--bg-secondary) 0%, var(--bg-primary) 100%); }

.section-header { text-align: center; margin-bottom: 3.5rem; }
.section-header h2 { margin-bottom: 1rem; }
.section-header p { color: var(--text-muted); font-size: 1.1rem; max-width: 600px; margin: 0 auto; line-height: 1.7; }

.section-label {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
  padding: 0.25rem 0.6rem;
  border-radius: 4px;
  background: rgba(251, 191, 36, 0.06);
  border: 1px solid rgba(251, 191, 36, 0.12);
}

/* ── Cards ── */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}

.card-grid-2 { grid-template-columns: repeat(auto-fill, minmax(420px, 1fr)); }

.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: var(--radius-lg);
  padding: 1px;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.15) 0%, transparent 40%, transparent 60%, rgba(139, 92, 246, 0.1) 100%);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--transition);
}

.card:hover {
  background: var(--card-hover);
  border-color: var(--border-hover);
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4), 0 0 30px rgba(251, 191, 36, 0.06);
}

.card:hover::before { opacity: 1; }

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1.25rem;
  background: rgba(251, 191, 36, 0.08);
  border: 1px solid rgba(251, 191, 36, 0.15);
  box-shadow: 0 0 16px rgba(251, 191, 36, 0.08);
}

.card h3 { margin-bottom: 0.6rem; color: #f8fafc; }
.card p { color: var(--text-muted); font-size: 0.95rem; flex: 1; line-height: 1.7; }
.card-footer { margin-top: 1.5rem; display: flex; gap: 0.5rem; flex-wrap: wrap; }

.badge {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.3rem 0.7rem;
  border-radius: 100px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.badge-green { background: rgba(34, 197, 94, 0.1); color: #4ade80; border: 1px solid rgba(34, 197, 94, 0.2); }
.badge-blue { background: rgba(0, 212, 255, 0.08); color: var(--accent); border: 1px solid rgba(0, 212, 255, 0.18); }
.badge-orange { background: rgba(249, 115, 22, 0.1); color: #fb923c; border: 1px solid rgba(249, 115, 22, 0.2); }

/* ── Product page ── */
.product-hero {
  padding: 5.5rem 1.5rem 3.5rem;
  border-bottom: 1px solid var(--border);
  position: relative;
}

.product-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 50% at 50% 0%, rgba(139, 92, 246, 0.08) 0%, transparent 60%);
  pointer-events: none;
}

.product-hero .container { position: relative; z-index: 1; }
.product-hero .eyebrow { margin-bottom: 1.25rem; }
.product-hero h1 { margin-bottom: 1.25rem; }

.product-hero .lead {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 700px;
  margin-bottom: 2rem;
  line-height: 1.7;
}

.product-hero .actions { display: flex; gap: 0.875rem; flex-wrap: wrap; }

.page-content { padding: 4rem 1.5rem; }
.page-content .container { max-width: 800px; }

.page-content h2 {
  margin-top: 3rem;
  margin-bottom: 1rem;
  color: #f8fafc;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

.page-content h3 { margin-top: 2rem; margin-bottom: 0.6rem; color: #cbd5e1; }
.page-content ul, .page-content ol { padding-left: 1.5rem; margin-bottom: 1.25rem; }
.page-content li { margin-bottom: 0.4rem; color: var(--text-muted); }
.page-content li strong { color: #f8fafc; }

.page-content blockquote {
  border-left: 3px solid var(--accent);
  padding: 1rem 1.5rem;
  margin: 2rem 0;
  background: rgba(139, 92, 246, 0.04);
  border-radius: 0 var(--radius) var(--radius) 0;
  color: var(--text-muted);
  font-style: italic;
  box-shadow: 4px 0 20px rgba(139, 92, 246, 0.04);
}

/* ── Feature list ── */
.feature-list { display: flex; flex-direction: column; gap: 1.75rem; margin: 2.5rem 0; }
.feature-item { display: flex; gap: 1.25rem; }

.feature-item-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(0, 212, 255, 0.08);
  border: 1px solid rgba(0, 212, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  margin-top: 2px;
  box-shadow: 0 0 12px rgba(0, 212, 255, 0.06);
}

.feature-item-body h4 { margin-bottom: 0.35rem; color: #f8fafc; }
.feature-item-body p { color: var(--text-muted); font-size: 0.95rem; line-height: 1.7; }

/* ── Pillars ── */
.pillars { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 1.5rem; margin: 2.5rem 0; }

.pillar {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  transition: all var(--transition);
}

.pillar:hover {
  border-color: var(--border-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.pillar-num {
  font-family: var(--font-mono);
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--accent);
  opacity: 0.35;
  line-height: 1;
  margin-bottom: 0.6rem;
}

.pillar h4 { color: #f8fafc; margin-bottom: 0.5rem; }
.pillar p { font-size: 0.9rem; color: var(--text-muted); line-height: 1.7; }

/* ── Skills / Modules grid ── */
.modules-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.25rem;
  margin-top: 2rem;
}

.module-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.75rem;
  transition: all var(--transition);
}

.module-card:hover {
  border-color: var(--border-hover);
  background: var(--card-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.module-num {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.4rem;
}

.module-card h3 { font-size: 1.1rem; color: #f8fafc; margin-bottom: 0.5rem; }
.module-card p { font-size: 0.9rem; color: var(--text-muted); margin: 0; line-height: 1.7; }
.module-meta { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-top: 1rem; }

/* ── Stack comparison table ── */
.stack-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin: 2.5rem 0;
  font-size: 0.95rem;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
}

.stack-table th, .stack-table td { padding: 0.9rem 1.25rem; text-align: left; }
.stack-table th {
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: var(--bg-tertiary);
  font-family: var(--font-mono);
  border-bottom: 1px solid var(--border);
}

.stack-table td { color: var(--text); border-bottom: 1px solid var(--border); }
.stack-table tr:last-child td { border-bottom: none; }
.stack-table tr:hover td { background: rgba(251, 191, 36, 0.03); }
.stack-table .product-name { color: #f8fafc; font-weight: 600; }

/* ── CTA strip ── */
.cta-strip {
  background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-secondary) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 3.5rem 2.5rem;
  text-align: center;
  margin: 4rem 0 0;
  position: relative;
  overflow: hidden;
}

.cta-strip::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 50% at 50% 0%, rgba(139, 92, 246, 0.1) 0%, transparent 60%);
  pointer-events: none;
}

.cta-strip h2 { margin-bottom: 1rem; position: relative; }
.cta-strip p { color: var(--text-muted); margin-bottom: 2rem; max-width: 500px; margin-left: auto; margin-right: auto; position: relative; }
.cta-strip .actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; position: relative; }

/* ── Footer ── */
.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--border);
  padding: 3.5rem 1.5rem 2rem;
  background: linear-gradient(180deg, var(--bg-secondary) 0%, var(--bg-deep) 100%);
  position: relative;
}

.site-footer::before {
  content: '';
  position: absolute;
  top: -1px;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, var(--accent) 50%, transparent 100%);
  opacity: 0.3;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2rem;
  align-items: start;
}

.footer-brand .site-logo { font-size: 1.1rem; display: block; margin-bottom: 0.5rem; }
.footer-brand p { font-size: 0.88rem; color: var(--text-dim); max-width: 320px; line-height: 1.7; }

.footer-links { display: flex; gap: 1.75rem; list-style: none; }
.footer-links a { font-size: 0.88rem; color: var(--text-dim); transition: all var(--transition); }
.footer-links a:hover { color: var(--accent); }

.footer-copy {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-dim);
  font-family: var(--font-mono);
}

.footer-copy a { color: var(--text-dim); }
.footer-copy a:hover { color: var(--accent); }

/* ── Breadcrumb ── */
.breadcrumb { padding: 1.25rem 1.5rem; }
.breadcrumb-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  gap: 0.6rem;
  align-items: center;
  font-size: 0.85rem;
  color: var(--text-dim);
  font-family: var(--font-mono);
}

.breadcrumb-inner a { color: var(--text-dim); }
.breadcrumb-inner a:hover { color: var(--accent); }
.breadcrumb-inner span.sep { opacity: 0.4; }

/* ── About page ── */
.about-intro { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; margin-bottom: 4rem; }

/* ── Logo in footer brand ── */
.footer-brand .site-logo img {
  height: 28px;
  width: auto;
  filter: drop-shadow(0 0 6px rgba(251, 191, 36, 0.2));
}

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

.hero .container > * {
  animation: fadeInUp 0.6s ease forwards;
}

.hero .container > *:nth-child(1) { animation-delay: 0.1s; opacity: 0; }
.hero .container > *:nth-child(2) { animation-delay: 0.2s; opacity: 0; }
.hero .container > *:nth-child(3) { animation-delay: 0.3s; opacity: 0; }
.hero .container > *:nth-child(4) { animation-delay: 0.4s; opacity: 0; }

/* ── Responsive ── */
@media (max-width: 768px) {
  .hero { padding: 5rem 1rem 4rem; }
  .card-grid-2 { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; gap: 1.5rem; }
  .footer-links { flex-wrap: wrap; gap: 1rem; }
  .pillars { grid-template-columns: 1fr 1fr; }
  .about-intro { grid-template-columns: 1fr; }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(5, 10, 20, 0.98);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 1rem 1.5rem;
    gap: 0.25rem;
  }

  .nav-links.open { display: flex; }
  .nav-links a { width: 100%; padding: 0.6rem 0.75rem; }
  .nav-mobile-toggle { display: flex; margin-left: auto; }
  .nav-lang { margin-left: 0; margin-top: 0.5rem; width: fit-content; }
}

@media (max-width: 480px) {
  .pillars { grid-template-columns: 1fr; }
  .modules-grid { grid-template-columns: 1fr; }
  .card-grid { grid-template-columns: 1fr; }
  .cta-strip { padding: 2.5rem 1.5rem; }
  .section { padding: 4rem 1rem; }
}

/* ── Utilities ── */
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.gap-1 { gap: 0.5rem; }
.flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
