/* ==========================================================================
   Fluid Technologies - styles.css
   Flat, dark, clean. No gradients, no shadows.
   ========================================================================== */

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

:root {
  /* Colour system */
  --navy: #0D1B2A;
  --navy-mid: #1A2E44;
  --accent: #3B82F6;
  --accent-hover: #2563EB;
  --accent-soft: #60A5FA;
  --text-primary: #F1F5F9;
  --text-secondary: #94A3B8;
  --text-muted: #64748B;

  /* Surfaces & borders */
  --surface: rgba(255, 255, 255, 0.04);
  --surface-hover: rgba(255, 255, 255, 0.07);
  --border: rgba(255, 255, 255, 0.08);
  --border-hover: rgba(255, 255, 255, 0.15);
  --border-strong: rgba(255, 255, 255, 0.3);

  /* Status accent (active badge) */
  --live: #34D399;
  --live-bg: rgba(16, 185, 129, 0.12);
  --live-border: rgba(16, 185, 129, 0.2);

  /* Radii */
  --radius: 12px;
  --radius-lg: 20px;

  /* Nav surface (opacity adjusted on scroll via .scrolled) */
  --nav-bg: rgba(13, 27, 42, 0.65);
  --nav-bg-scrolled: rgba(13, 27, 42, 0.92);

  /* Layout */
  --max-width: 1100px;

  /* Type */
  --font-display: 'Sora', sans-serif;
  --font-body: 'Inter', sans-serif;
}

html { scroll-behavior: smooth; }

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

/* ==========================================================================
   NAV
   ========================================================================== */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 0 2rem; height: 64px;
  display: flex; align-items: center; justify-content: space-between;
  background: var(--nav-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: background 0.3s ease;
}
nav.scrolled { background: var(--nav-bg-scrolled); }

.nav-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.nav-logo img { width: 30px; height: 30px; display: block; }
.nav-logo-text {
  font-family: var(--font-display); font-weight: 600; font-size: 18px;
  color: var(--text-primary); letter-spacing: -0.3px;
}
.nav-logo-text span { color: var(--accent-soft); }

nav ul { list-style: none; display: flex; gap: 2rem; }
nav ul a {
  color: var(--text-secondary); text-decoration: none;
  font-size: 14px; font-weight: 400; transition: color 0.2s;
}
nav ul a:hover { color: var(--text-primary); }
nav ul a.active { color: var(--text-primary); }

/* ==========================================================================
   HERO
   ========================================================================== */
#hero {
  min-height: 100vh; display: flex; flex-direction: column; justify-content: center;
  padding: 120px 2rem 60px; max-width: var(--max-width); margin: 0 auto;
}
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 500; letter-spacing: 1.5px;
  text-transform: uppercase; color: var(--accent-soft); margin-bottom: 2rem;
}
.hero-eyebrow::before {
  content: ''; display: inline-block; width: 24px; height: 1.5px; background: var(--accent-soft);
}
h1 {
  font-family: var(--font-display);
  font-size: clamp(42px, 6vw, 72px); font-weight: 700;
  line-height: 1.08; letter-spacing: -2px; margin-bottom: 1.5rem;
}
h1 em { font-style: normal; color: var(--accent-soft); }
.hero-sub {
  font-size: clamp(16px, 2vw, 20px); color: var(--text-secondary);
  max-width: 560px; line-height: 1.7; font-weight: 300; margin-bottom: 3rem;
}
.hero-cta { display: flex; gap: 1rem; flex-wrap: wrap; }

.btn-primary {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--accent); color: #fff; padding: 12px 24px;
  border-radius: var(--radius); font-size: 14px; font-weight: 500;
  text-decoration: none; transition: background 0.2s, transform 0.15s;
}
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-1px); }
.btn-ghost {
  display: inline-flex; align-items: center; gap: 6px;
  background: transparent; color: var(--text-secondary); padding: 12px 24px;
  border-radius: var(--radius); border: 1px solid var(--border-hover);
  font-size: 14px; font-weight: 400; text-decoration: none;
  transition: color 0.2s, border-color 0.2s;
}
.btn-ghost:hover { color: var(--text-primary); border-color: var(--border-strong); }

/* ==========================================================================
   SECTIONS (shared)
   ========================================================================== */
section { padding: 100px 2rem; max-width: var(--max-width); margin: 0 auto; }
.section-label {
  font-size: 11px; font-weight: 500; letter-spacing: 2px;
  text-transform: uppercase; color: var(--accent-soft); margin-bottom: 1rem;
}
h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 4vw, 44px); font-weight: 700;
  letter-spacing: -1px; line-height: 1.1; margin-bottom: 1rem;
}
.section-intro {
  color: var(--text-secondary); font-size: 17px;
  max-width: 520px; line-height: 1.7; font-weight: 300; margin-bottom: 3.5rem;
}

/* ==========================================================================
   ABOUT
   ========================================================================== */
#about { border-top: 1px solid var(--border); }
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
.about-copy p {
  color: var(--text-secondary); font-size: 16px;
  line-height: 1.8; font-weight: 300; margin-bottom: 1.2rem;
}
.about-copy p strong { color: var(--text-primary); font-weight: 500; }
.about-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.stat-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.5rem;
  transition: border-color 0.2s, background 0.2s;
}
.stat-card:hover { background: var(--surface-hover); border-color: var(--border-hover); }
.stat-num {
  font-family: var(--font-display); font-size: 32px; font-weight: 700;
  color: var(--text-primary); letter-spacing: -1px; line-height: 1; margin-bottom: 4px;
}
.stat-num span { color: var(--accent-soft); }
.stat-label { font-size: 13px; color: var(--text-muted); }

/* ==========================================================================
   WORK
   ========================================================================== */
#work { border-top: 1px solid var(--border); }
.work-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-bottom: 1.5rem; }
.project-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 2rem;
  text-decoration: none; color: inherit;
  display: flex; flex-direction: column;
  transition: border-color 0.2s, background 0.2s, transform 0.2s;
  position: relative;
}
.project-card:hover {
  border-color: var(--border-hover); background: var(--surface-hover); transform: translateY(-2px);
}
.card-badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11px; font-weight: 500; letter-spacing: 1px;
  text-transform: uppercase; padding: 4px 10px;
  border-radius: 100px; margin-bottom: 1.25rem; width: fit-content;
}
.badge-live {
  background: var(--live-bg); color: var(--live);
  border: 1px solid var(--live-border);
}
.badge-live::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%;
  background: var(--live); display: inline-block;
}
.badge-past {
  background: rgba(148, 163, 184, 0.1); color: var(--text-muted); border: 1px solid var(--border);
}

/* Project logo area */
.project-logo-wrap {
  min-height: 64px; display: flex; align-items: center; margin-bottom: 1.25rem;
}
.project-logo-wrap img {
  height: 44px; width: auto; object-fit: contain; display: block;
}
/* Square crest-style logos read better a little larger */
.project-logo-wrap img.logo-emblem { height: 64px; }
.project-logo-fallback { display: none; align-items: center; gap: 8px; }
.project-logo-fallback .emoji { font-size: 28px; }
.project-logo-fallback .name {
  font-family: var(--font-display); font-size: 20px; font-weight: 600; color: var(--text-primary);
}
.project-logo-fallback .name-soft { font-weight: 300; color: var(--text-secondary); }
.project-icon {
  width: 48px; height: 48px; border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; margin-bottom: 1.25rem; flex-shrink: 0;
}
.icon-care { background: rgba(20, 184, 166, 0.15); }
.icon-referral { background: rgba(234, 179, 8, 0.15); }
.icon-cycle { background: rgba(34, 197, 94, 0.15); }

.project-title {
  font-family: var(--font-display); font-size: 20px; font-weight: 600;
  color: var(--text-primary); margin-bottom: 0.5rem; letter-spacing: -0.3px;
}
.project-desc {
  font-size: 14px; color: var(--text-secondary);
  line-height: 1.7; font-weight: 300; flex: 1;
}
.project-meta { margin-top: 1.5rem; display: flex; gap: 0.5rem; flex-wrap: wrap; }
.tag {
  font-size: 11px; font-weight: 500; color: var(--text-muted);
  background: var(--surface); border: 1px solid var(--border);
  padding: 3px 10px; border-radius: 100px;
}
.arrow-link {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 500; color: var(--accent-soft);
  margin-top: 1.25rem; transition: gap 0.15s;
}
.project-card:hover .arrow-link { gap: 10px; }

/* Past projects */
.work-divider {
  font-size: 13px; font-weight: 500; color: var(--text-muted);
  letter-spacing: 1px; text-transform: uppercase;
  display: flex; align-items: center; gap: 1rem;
  margin-bottom: 1.5rem; margin-top: 3rem;
}
.work-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.past-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.past-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.5rem;
  transition: border-color 0.2s, background 0.2s;
}
.past-card:hover { background: var(--surface-hover); border-color: var(--border-hover); }
.past-card .project-icon { width: 40px; height: 40px; font-size: 18px; margin-bottom: 1rem; }
.past-card .project-title { font-size: 16px; margin-bottom: 0.4rem; }
.past-card .project-desc { font-size: 13px; }

/* ==========================================================================
   FOUNDER
   ========================================================================== */
#founder { border-top: 1px solid var(--border); }
.founder-grid { display: grid; grid-template-columns: auto 1fr; gap: 3rem; align-items: start; }
.founder-avatar {
  width: 100px; height: 100px; border-radius: 50%;
  background: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-size: 32px; font-weight: 700;
  color: #fff; flex-shrink: 0; border: 2px solid var(--border-hover);
}
.founder-name {
  font-family: var(--font-display); font-size: 28px; font-weight: 700;
  letter-spacing: -0.5px; margin-bottom: 4px;
}
.founder-title { font-size: 14px; color: var(--accent-soft); font-weight: 500; margin-bottom: 1.5rem; }
.founder-bio p {
  color: var(--text-secondary); font-size: 16px;
  line-height: 1.8; font-weight: 300; margin-bottom: 1rem;
}
.founder-bio p strong { color: var(--text-primary); font-weight: 500; }
.linkedin-link {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--text-secondary); text-decoration: none; font-size: 14px; font-weight: 400;
  border: 1px solid var(--border); padding: 8px 16px; border-radius: var(--radius);
  margin-top: 0.5rem; transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.linkedin-link:hover { color: var(--text-primary); border-color: var(--border-hover); background: var(--surface-hover); }

/* ==========================================================================
   CONTACT
   ========================================================================== */
#contact { border-top: 1px solid var(--border); text-align: center; }
#contact h2 { margin: 0 auto 1rem; }
#contact .section-intro { margin: 0 auto 2.5rem; }
#contact .section-label { display: block; text-align: center; }
.contact-email {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 20px; font-weight: 400; color: var(--accent-soft);
  text-decoration: none; border: 1px solid rgba(96, 165, 250, 0.3);
  padding: 16px 32px; border-radius: var(--radius-lg);
  background: rgba(59, 130, 246, 0.06);
  transition: background 0.2s, border-color 0.2s;
  font-family: var(--font-body);
}
.contact-email:hover { background: rgba(59, 130, 246, 0.1); border-color: rgba(96, 165, 250, 0.5); }

/* ==========================================================================
   FOOTER
   ========================================================================== */
footer {
  border-top: 1px solid var(--border); padding: 2rem;
  max-width: var(--max-width); margin: 0 auto;
  display: flex; justify-content: space-between; align-items: center;
}
footer p { font-size: 13px; color: var(--text-muted); }
footer a { color: var(--text-muted); text-decoration: none; font-size: 13px; }
footer a:hover { color: var(--text-secondary); }

/* ==========================================================================
   SCROLL FADE-IN (IntersectionObserver)
   ========================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 768px) {
  nav { padding: 0 1.25rem; }
  nav ul { display: none; }
  .about-grid, .work-grid, .founder-grid { grid-template-columns: 1fr; }
  .about-grid, .founder-grid { gap: 2.5rem; }
  .past-grid { grid-template-columns: 1fr; }
  section { padding: 80px 1.25rem; }
  #hero { padding-left: 1.25rem; padding-right: 1.25rem; }
  footer { flex-direction: column; gap: 0.75rem; text-align: center; }
}

@media (max-width: 420px) {
  .about-stats { grid-template-columns: 1fr 1fr; gap: 0.75rem; }
  .stat-card { padding: 1.25rem; }
  .project-card { padding: 1.5rem; }
  .contact-email { font-size: 16px; padding: 14px 22px; }
}
