/* === Fonts === */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@600;700&family=Lato:wght@300;400;700;900&display=swap');

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

/* === Variables === */
:root {
  /* 1. Rich dark palette — deep navy blue for trust and premium feel */
  --bg: #020617;
  --bg-elevated: #0f172a;
  --surface: rgba(255, 255, 255, 0.03);
  --surface-border: rgba(255, 255, 255, 0.06);
  --border: rgba(255, 255, 255, 0.08);
  --text: #f1f5f9;
  --text-muted: #94a3b8;
  --accent: #06B6D4;
  --accent-warm: #f59e0b;
  --accent-secondary: #3B82F6;
  /* 2. Gradient accent — cyan to warm amber */
  --gradient-accent: linear-gradient(135deg, #06B6D4 0%, #f59e0b 100%);
  --gradient-accent-subtle: linear-gradient(135deg, rgba(6, 182, 212, 0.5) 0%, rgba(245, 158, 11, 0.5) 100%);
  --font-heading: 'Poppins', 'Helvetica Neue', Arial, sans-serif;
  --font-body: 'Lato', 'Helvetica Neue', Arial, sans-serif;

  /* 4. Project brand colors */
  --color-notedrx: #0d7a5f;
  --color-getcuspid: #6366f1;
  --color-ismymodlegal: #e8820e;
  --color-ishemplegal: #16a34a;
}

/* === Base === */
html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  position: relative;
}

/* Noise texture overlay */
body::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0.025;
  z-index: 1000;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px 256px;
}

/* 5. Ambient background glow orbs */
.ambient-glow {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.ambient-glow .orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
}

.ambient-glow .orb-red {
  width: 600px;
  height: 600px;
  background: rgba(6, 182, 212, 0.08);
  top: -150px;
  right: -100px;
}

.ambient-glow .orb-indigo {
  width: 600px;
  height: 600px;
  background: rgba(245, 158, 11, 0.05);
  bottom: -200px;
  left: -150px;
}

.ambient-glow .orb-orange {
  width: 500px;
  height: 500px;
  background: rgba(245, 158, 11, 0.03);
  top: 40%;
  right: -100px;
  left: auto;
}

/* 3. Faint background grid texture */
.ambient-glow::after {
  content: '';
  position: absolute;
  inset: 0;
  background-size: 40px 40px;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  mask-image: radial-gradient(ellipse at top, black 20%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse at top, black 20%, transparent 80%);
}

a {
  color: inherit;
  text-decoration: none;
}

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

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

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

@keyframes accentLine {
  from { width: 0; }
  to { width: 50px; }
}

.animate {
  opacity: 0;
}

.animate.visible {
  animation: fadeUp 0.6s ease forwards;
}

.animate-delay-1 { animation-delay: 0.1s !important; }
.animate-delay-2 { animation-delay: 0.2s !important; }
.animate-delay-3 { animation-delay: 0.3s !important; }
.animate-delay-4 { animation-delay: 0.4s !important; }
.animate-delay-5 { animation-delay: 0.5s !important; }
.animate-delay-6 { animation-delay: 0.6s !important; }
.animate-delay-7 { animation-delay: 0.7s !important; }

/* === Navigation === */
/* 2. Gradient top-edge stripe */
.nav::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent 0%, #06B6D4 25%, #f59e0b 75%, transparent 100%);
}

.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 24px 40px 0;
  background-color: var(--bg);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  display: flex;
  align-items: center;
}

.nav-logo-svg {
  height: 130px;
  width: auto;
}

.nav-links {
  display: flex;
  gap: 36px;
  list-style: none;
  padding: 14px 0;
}

.nav-links a {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--text-muted);
  transition: color 0.3s;
  position: relative;
  padding-bottom: 2px;
}

/* 2. Gradient animated underline on hover */
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 50%;
  right: 50%;
  height: 2px;
  background: var(--gradient-accent);
  transition: left 0.3s ease, right 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  left: 0;
  right: 0;
}

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

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

/* Hamburger (hidden on desktop) */
.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  position: absolute;
  right: 24px;
  top: 50%;
  transform: translateY(-50%);
}

.nav-hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--text);
  transition: transform 0.3s, opacity 0.3s;
}

/* === Hero === */
.hero {
  text-align: center;
  padding: 70px 40px 80px;
  position: relative;
}

/* Radial glow behind hero */
.hero::before {
  content: '';
  position: absolute;
  top: 40%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 700px;
  height: 500px;
  background: radial-gradient(ellipse, rgba(6, 182, 212, 0.08) 0%, rgba(245, 158, 11, 0.04) 40%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

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

.hero-label {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--accent);
  letter-spacing: 6px;
  text-transform: uppercase;
  font-weight: 900;
  margin-bottom: 20px;
}

.hero-title {
  font-family: var(--font-heading);
  font-size: 44px;
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 24px;
  letter-spacing: -0.5px;
}

.hero-title em {
  font-style: normal;
  background: var(--gradient-accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-rule {
  width: 50px;
  height: 3px;
  background: var(--gradient-accent);
  border: none;
  margin: 0 auto 24px;
}

.hero-rule.visible {
  animation: accentLine 0.8s ease forwards;
  animation-delay: 0.3s;
}

.hero-description {
  font-size: 17px;
  color: var(--text-muted);
  max-width: 480px;
  margin: 0 auto;
  font-weight: 300;
  line-height: 1.7;
}

/* === Section === */
.section {
  padding: 80px 40px;
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border);
  background: linear-gradient(180deg, var(--bg-elevated) 0%, var(--bg) 100%);
}

.section-label {
  font-family: var(--font-body);
  font-size: 11px;
  color: var(--accent);
  letter-spacing: 6px;
  text-transform: uppercase;
  font-weight: 900;
  margin-bottom: 36px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* 2. Gradient stripe accent — brand motif */
.section-label::before {
  content: '';
  display: inline-block;
  width: 20px;
  height: 2px;
  background: var(--gradient-accent);
  vertical-align: middle;
  margin-right: 12px;
}

/* === Project Cards === */
.project-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  max-width: 800px;
  margin: 0 auto;
}

/* 3. Glassmorphism cards */
.project-card {
  background: var(--surface);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 12px;
  padding: 32px 28px 28px;
  text-align: center;
  border: 1px solid var(--surface-border);
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.project-card-icon {
  width: 64px;
  height: 64px;
  border-radius: 14px;
  margin-bottom: 18px;
  object-fit: cover;
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.project-card-icon-svg {
  width: 64px;
  height: 64px;
  margin-bottom: 18px;
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* 1. Icon zoom on card hover */
.project-card:hover .project-card-icon,
.project-card:hover .project-card-icon-svg {
  transform: scale(1.15) translateY(-4px);
}

/* 2. Gradient accent line on hover */
.project-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 3px;
  background: var(--gradient-accent);
  transition: width 0.4s ease;
}

/* Default hover — gradient */
.project-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
}

.project-card:hover::before {
  width: 100%;
}

/* 4. Dynamic hover effects using project colors */
.project-card[data-brand="notedrx"]:hover {
  border-color: rgba(13, 122, 95, 0.4);
  box-shadow: 0 12px 40px rgba(13, 122, 95, 0.15), 0 0 80px rgba(13, 122, 95, 0.05);
}
.project-card[data-brand="notedrx"]::before {
  background: linear-gradient(90deg, #0d7a5f, #10b981);
}

.project-card[data-brand="getcuspid"]:hover {
  border-color: rgba(99, 102, 241, 0.4);
  box-shadow: 0 12px 40px rgba(99, 102, 241, 0.15), 0 0 80px rgba(99, 102, 241, 0.05);
}
.project-card[data-brand="getcuspid"]::before {
  background: linear-gradient(90deg, #6366f1, #a78bfa);
}

.project-card[data-brand="ismymodlegal"]:hover {
  border-color: rgba(232, 130, 14, 0.4);
  box-shadow: 0 12px 40px rgba(232, 130, 14, 0.15), 0 0 80px rgba(232, 130, 14, 0.05);
}
.project-card[data-brand="ismymodlegal"]::before {
  background: linear-gradient(90deg, #e8820e, #f59e0b);
}

.project-card[data-brand="ishemplegal"]:hover {
  border-color: rgba(22, 163, 74, 0.4);
  box-shadow: 0 12px 40px rgba(22, 163, 74, 0.15), 0 0 80px rgba(22, 163, 74, 0.05);
}
.project-card[data-brand="ishemplegal"]::before {
  background: linear-gradient(90deg, #16a34a, #10b981);
}

.project-card-name {
  font-family: var(--font-heading);
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
  transition: color 0.3s ease;
}

.project-card[data-brand="notedrx"]:hover .project-card-name { color: #34d399; }
.project-card[data-brand="getcuspid"]:hover .project-card-name { color: #a78bfa; }
.project-card[data-brand="ismymodlegal"]:hover .project-card-name { color: #fbbf24; }
.project-card[data-brand="ishemplegal"]:hover .project-card-name { color: #4ade80; }

.project-card-desc {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 300;
  line-height: 1.6;
}

/* 2. Pill/outline button for Visit Site */
.project-card-link {
  display: inline-block;
  margin-top: 20px;
  padding: 8px 20px;
  border-radius: 99px;
  border: 1px solid var(--border);
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 2px;
  font-weight: 700;
  text-transform: uppercase;
  transition: all 0.3s ease;
}

.project-card:hover .project-card-link {
  border-color: currentColor;
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
  letter-spacing: 3px;
}

/* === About === */
.about-content {
  max-width: 700px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.about-content h2 {
  font-family: var(--font-heading);
  font-size: 26px;
  font-weight: 700;
  margin-bottom: 18px;
}

.about-content p {
  font-size: 16px;
  color: var(--text-muted);
  font-weight: 300;
  line-height: 1.9;
  margin-bottom: 22px;
}

.about-content .accent {
  color: var(--accent);
  font-weight: 500;
}

.about-divider {
  width: 50px;
  height: 3px;
  background: var(--gradient-accent);
  border: none;
  margin: 48px 0;
}

/* === Footer === */
.footer {
  text-align: center;
  padding: 40px 40px;
  border-top: 1px solid var(--border);
  font-size: 12px;
  color: var(--text-muted);
  letter-spacing: 1px;
  position: relative;
  z-index: 1;
}

/* 2. Gradient top-edge stripe on footer */
.footer::before {
  content: '';
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: var(--gradient-accent);
}

/* === Responsive === */
@media (max-width: 768px) {
  .nav {
    padding: 16px 24px 0;
  }

  .nav-logo-svg {
    height: 90px;
  }

  .nav-hamburger {
    display: flex;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: center;
    background-color: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 20px 24px;
    gap: 16px;
  }

  .nav-links.open {
    display: flex;
  }

  .hero {
    padding: 50px 24px 60px;
  }

  .hero::before {
    width: 350px;
    height: 300px;
  }

  .hero-title {
    font-size: 30px;
  }

  .section {
    padding: 50px 24px;
  }

  .project-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .ambient-glow .orb {
    opacity: 0.7;
  }

  .footer {
    padding: 30px 24px;
  }
}
