/* ============================================================
   HexPi IT GROUP — Main Stylesheet
   Modern, dark-first, AI-forward design
   ============================================================ */

/* ── CSS Variables ─────────────────────────────────────────── */
:root {
  /* Colours */
  --clr-bg: #0d0f1a;
  --clr-bg-alt: #111422;
  --clr-surface: #181b2e;
  --clr-surface-2: #1e2238;
  --clr-border: rgba(255, 255, 255, 0.08);

  --clr-blue: #4a6cf7;
  --clr-blue-light: #6b8aff;
  --clr-blue-dark: #2563eb;
  --clr-blue-glow: rgba(74, 108, 247, 0.35);
  --clr-teal: #06b6d4;
  --clr-green: #22c55e;
  --clr-purple: #a855f7;

  --clr-text: #f1f5f9;
  --clr-text-muted: #94a3b8;
  --clr-text-dim: #64748b;

  --clr-white: #ffffff;

  /* Light section */
  --clr-light-bg: #f8faff;
  --clr-light-surface: #ffffff;
  --clr-light-text: #0f172a;
  --clr-light-muted: #475569;
  --clr-light-border: #e2e8f0;

  /* Typography */
  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  /* Spacing */
  --nav-h: 72px;

  /* Radius */
  --r-sm: 6px;
  --r-md: 12px;
  --r-lg: 20px;
  --r-xl: 32px;

  /* Transitions */
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-h);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  background: var(--clr-bg);
  color: var(--clr-text);
  line-height: 1.65;
  overflow-x: hidden;
}

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

ul {
  list-style: none;
}

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

button {
  cursor: pointer;
  font-family: inherit;
}

/* ── Utility ────────────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 3rem);
}

.gradient-text {
  background: linear-gradient(135deg, var(--clr-blue-light) 0%, var(--clr-teal) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Buttons ────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 1.75rem;
  border-radius: var(--r-md);
  font-weight: 600;
  font-size: 0.975rem;
  letter-spacing: 0.01em;
  transition: all 0.25s var(--ease);
  border: 2px solid transparent;
  white-space: nowrap;
}

.btn svg {
  width: 1.1em;
  height: 1.1em;
  flex-shrink: 0;
}

.btn-primary {
  background: var(--clr-blue);
  color: var(--clr-white);
  border-color: var(--clr-blue);
  box-shadow: 0 0 0 0 var(--clr-blue-glow);
}

.btn-primary:hover {
  background: var(--clr-blue-light);
  border-color: var(--clr-blue-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px var(--clr-blue-glow);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-ghost {
  background: transparent;
  color: var(--clr-text);
  border-color: var(--clr-border);
  backdrop-filter: blur(4px);
}

.btn-ghost:hover {
  border-color: var(--clr-blue);
  color: var(--clr-blue-light);
  transform: translateY(-2px);
}

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

/* ── Navigation ─────────────────────────────────────────────── */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 1000;
  height: var(--nav-h);
  background: rgba(13, 15, 26, 0.7);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border-bottom: 1px solid var(--clr-border);
  transition: background 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.site-header.scrolled {
  background: rgba(13, 15, 26, 0.95);
  box-shadow: 0 4px 32px rgba(0, 0, 0, 0.4);
}

.nav-container {
  max-width: 1200px;
  height: 100%;
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 3rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  flex-shrink: 0;
}

.logo-icon {
  width: 36px;
  height: 30px;
}

.logo-icon--small {
  width: 28px;
  height: 24px;
}

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.logo-name {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--clr-white);
  letter-spacing: -0.01em;
}

.logo-sub {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--clr-text-muted);
}

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

.nav-link {
  padding: 0.5rem 0.875rem;
  border-radius: var(--r-sm);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--clr-text-muted);
  transition: color 0.2s, background 0.2s;
}

.nav-link:hover {
  color: var(--clr-white);
  background: rgba(255, 255, 255, 0.06);
}

.nav-link.nav-cta {
  background: var(--clr-blue);
  color: var(--clr-white);
  font-weight: 600;
  padding: 0.5rem 1.1rem;
  margin-left: 0.5rem;
  border-radius: var(--r-md);
}

.nav-link.nav-cta:hover {
  background: var(--clr-blue-light);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: transparent;
  border: none;
  padding: 0;
}

.nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--clr-text);
  border-radius: 2px;
  transition: all 0.3s var(--ease);
  transform-origin: center;
}

.nav-toggle.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle.open span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.nav-toggle.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ── Hero ───────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: var(--clr-bg);
}

.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 1;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg,
      rgba(13, 15, 26, 0.72) 0%,
      rgba(22, 30, 80, 0.60) 50%,
      rgba(13, 15, 26, 0.75) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 800px;
  margin-inline: auto;
  text-align: center;
  padding: calc(var(--nav-h) + 2rem) clamp(1.25rem, 5vw, 3rem) 4rem;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.875rem;
  border-radius: 999px;
  background: rgba(74, 108, 247, 0.15);
  border: 1px solid rgba(74, 108, 247, 0.4);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--clr-blue-light);
  margin-bottom: 1.5rem;
  backdrop-filter: blur(8px);
}

.badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--clr-blue-light);
  box-shadow: 0 0 6px var(--clr-blue-light);
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {

  0%,
  100% {
    opacity: 1;
    box-shadow: 0 0 6px var(--clr-blue-light);
  }

  50% {
    opacity: 0.6;
    box-shadow: 0 0 12px var(--clr-blue-light);
  }
}

.hero-title {
  font-size: clamp(2rem, 5.5vw, 3.75rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.025em;
  color: var(--clr-white);
  margin-bottom: 1.25rem;
}

.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--clr-text-muted);
  max-width: 580px;
  margin-inline: auto;
  margin-bottom: 2.5rem;
  line-height: 1.75;
}

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

.hero-scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--clr-text-dim);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  animation: bounce-hint 2.5s ease-in-out infinite;
}

.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--clr-blue), transparent);
}

@keyframes bounce-hint {

  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }

  50% {
    transform: translateX(-50%) translateY(8px);
  }
}

/* ── Sections ───────────────────────────────────────────────── */
.section {
  padding-block: clamp(4rem, 8vw, 7rem);
}

.section--light {
  background: var(--clr-light-bg);
  color: var(--clr-light-text);
}

.section--dark {
  background: var(--clr-bg-alt);
  color: var(--clr-text);
}

.section-header {
  text-align: center;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}

.section-label {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--clr-blue);
  margin-bottom: 0.75rem;
}

.section-label--blue {
  color: var(--clr-blue-light);
}

.section-title {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--clr-light-text);
  line-height: 1.2;
  margin-bottom: 1rem;
}

.section-title--light {
  color: var(--clr-white);
}

.section-intro {
  max-width: 620px;
  margin-inline: auto;
  color: var(--clr-light-muted);
  font-size: 1.05rem;
  line-height: 1.75;
}

.section-intro--light {
  color: var(--clr-text-muted);
}

.title-rule {
  width: 48px;
  height: 3px;
  background: linear-gradient(to right, var(--clr-blue), var(--clr-teal));
  border-radius: 999px;
  margin-inline: auto;
  margin-bottom: 1rem;
}

/* ── Services ───────────────────────────────────────────────── */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.service-card {
  background: var(--clr-light-surface);
  border: 1px solid var(--clr-light-border);
  border-radius: var(--r-lg);
  padding: 2rem;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 48px rgba(74, 108, 247, 0.12);
  border-color: rgba(74, 108, 247, 0.3);
}

.service-icon-wrap {
  width: 56px;
  height: 56px;
  border-radius: var(--r-md);
  background: rgba(74, 108, 247, 0.1);
  display: grid;
  place-items: center;
  color: var(--clr-blue);
  flex-shrink: 0;
}

.service-icon-wrap svg {
  width: 28px;
  height: 28px;
}

.service-name {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--clr-light-text);
  letter-spacing: -0.01em;
}

.service-desc {
  font-size: 0.925rem;
  color: var(--clr-light-muted);
  line-height: 1.7;
  flex: 1;
}

.service-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.5rem;
}

.service-tags li {
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  background: rgba(74, 108, 247, 0.08);
  color: var(--clr-blue-dark);
  border: 1px solid rgba(74, 108, 247, 0.2);
}

/* ── AI Section ─────────────────────────────────────────────── */
.ai-section {
  position: relative;
  overflow: hidden;
}

.ai-grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(74, 108, 247, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(74, 108, 247, 0.06) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 50%, black 40%, transparent 100%);
}

.ai-pillars {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 2rem;
  align-items: start;
  margin-bottom: 4rem;
}

.ai-pillar {
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  border-radius: var(--r-xl);
  padding: 2.25rem;
  transition: transform 0.3s var(--ease), border-color 0.3s, box-shadow 0.3s;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.ai-pillar:hover {
  transform: translateY(-6px);
  border-color: rgba(74, 108, 247, 0.4);
  box-shadow: 0 20px 60px rgba(74, 108, 247, 0.15);
}

.ai-pillar__icon {
  width: 64px;
  height: 64px;
  border-radius: var(--r-md);
  background: linear-gradient(135deg, rgba(74, 108, 247, 0.2) 0%, rgba(6, 182, 212, 0.1) 100%);
  border: 1px solid rgba(74, 108, 247, 0.3);
  display: grid;
  place-items: center;
  color: var(--clr-blue-light);
}

.ai-pillar__icon svg {
  width: 36px;
  height: 36px;
}

.ai-pillar h3 {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--clr-white);
  letter-spacing: -0.01em;
}

.ai-pillar>p {
  font-size: 0.925rem;
  color: var(--clr-text-muted);
  line-height: 1.75;
}

.ai-feature-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.ai-feature-list li {
  font-size: 0.875rem;
  color: var(--clr-text-muted);
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.ai-feature-list li::before {
  content: '';
  display: block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--clr-blue);
  flex-shrink: 0;
}

.ai-or {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-top: 4rem;
}

.ai-or span {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--clr-surface-2);
  border: 1px solid var(--clr-border);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--clr-text-muted);
}

/* AI Use Cases */
.ai-usecases {
  text-align: center;
  margin-bottom: 3rem;
}

.ai-usecases__title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--clr-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1.5rem;
}

.usecases-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
}

.usecase-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--clr-text-muted);
  transition: all 0.2s var(--ease);
}

.usecase-chip:hover {
  border-color: var(--clr-blue);
  color: var(--clr-blue-light);
  background: rgba(74, 108, 247, 0.1);
}

.usecase-chip svg {
  width: 16px;
  height: 16px;
}

.ai-cta {
  text-align: center;
}

.ai-cta p {
  font-size: 1rem;
  color: var(--clr-text-muted);
  margin-bottom: 1.25rem;
}

/* ── Portfolio ──────────────────────────────────────────────── */
.portfolio-grid {
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

.portfolio-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  background: var(--clr-light-surface);
  border: 1px solid var(--clr-light-border);
  border-radius: var(--r-xl);
  overflow: hidden;
}

.portfolio-card--reverse {
  direction: rtl;
}

.portfolio-card--reverse>* {
  direction: ltr;
}

.portfolio-card__visual {
  aspect-ratio: 4/3;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.portfolio-card__visual--dark {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
}

.portfolio-card__visual--green {
  background: linear-gradient(135deg, #052e16 0%, #065f46 50%, #064e3b 100%);
}

.portfolio-card__info {
  padding: 2.5rem 2.5rem 2.5rem 0;
}

.portfolio-card--reverse .portfolio-card__info {
  padding: 2.5rem 0 2.5rem 2.5rem;
}

.portfolio-type {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--clr-blue);
}

.portfolio-title {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--clr-light-text);
  letter-spacing: -0.02em;
  margin-top: 0.5rem;
}

.portfolio-rule {
  width: 40px;
  height: 3px;
  background: linear-gradient(to right, var(--clr-blue), var(--clr-teal));
  border-radius: 999px;
  margin-block: 1rem;
}

.portfolio-desc {
  font-size: 0.95rem;
  color: var(--clr-light-muted);
  line-height: 1.75;
  margin-bottom: 1.25rem;
}

.portfolio-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.portfolio-tags span {
  padding: 0.2rem 0.7rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  background: rgba(74, 108, 247, 0.08);
  color: var(--clr-blue-dark);
  border: 1px solid rgba(74, 108, 247, 0.2);
}

/* Mockup elements */
.portfolio-mockup {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  padding: 2rem;
}

.mockup-phone {
  width: 110px;
  background: #0d0d1a;
  border-radius: 18px;
  border: 2px solid rgba(255, 255, 255, 0.15);
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.mockup-tablet {
  width: 180px;
  background: #0d0d1a;
  border-radius: 12px;
  border: 2px solid rgba(255, 255, 255, 0.15);
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.mockup-screen {
  padding: 0;
}

.mockup-bar {
  height: 8px;
  background: rgba(74, 108, 247, 0.3);
}

.mockup-content {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mockup-line {
  height: 5px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.15);
}

.w-80 {
  width: 80%;
}

.w-70 {
  width: 70%;
}

.w-60 {
  width: 60%;
}

.w-50 {
  width: 50%;
}

.mockup-grid {
  display: flex;
  gap: 6px;
  margin-top: 4px;
}

.mockup-avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(74, 108, 247, 0.5), rgba(6, 182, 212, 0.3));
}

.mockup-btn-sm {
  width: 50px;
  height: 14px;
  border-radius: 4px;
  background: rgba(34, 197, 94, 0.4);
  margin-top: 4px;
}

/* Blue visual variant for portfolio cards */
.portfolio-card__visual--blue {
  background: linear-gradient(135deg, #0f1f3d 0%, #1a3a6b 50%, #0d2548 100%);
}

/* w-40 utility */
.w-40 {
  width: 40%;
}

/* Chat window mockup (Hexxy AI card) */
.mockup-chat-window {
  width: 190px;
  background: #0d0d1a;
  border-radius: 12px;
  border: 2px solid rgba(255, 255, 255, 0.15);
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.mockup-chat-bubble {
  border-radius: 10px;
  padding: 6px 8px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  max-width: 85%;
}

.mockup-chat-bubble--in {
  background: rgba(74, 108, 247, 0.25);
  align-self: flex-start;
  border-bottom-left-radius: 2px;
}

.mockup-chat-bubble--out {
  background: rgba(255, 255, 255, 0.1);
  align-self: flex-end;
  border-bottom-right-radius: 2px;
  margin-left: auto;
}

.mockup-content {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Stat row mockup (Moncton Honda card) */
.mockup-stat-row {
  display: flex;
  gap: 6px;
  margin-block: 4px;
}

.mockup-stat {
  flex: 1;
  height: 28px;
  border-radius: 6px;
  background: rgba(59, 130, 246, 0.25);
  border: 1px solid rgba(59, 130, 246, 0.3);
}

/* ── Contact ────────────────────────────────────────────────── */
.contact-section {
  background: var(--clr-bg);
  color: var(--clr-text);
}

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 3rem;
  align-items: start;
}

.contact-info__title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--clr-white);
  margin-bottom: 0.75rem;
}

.contact-info__body {
  color: var(--clr-text-muted);
  line-height: 1.75;
  font-size: 0.95rem;
  margin-bottom: 2rem;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.contact-item__icon {
  width: 40px;
  height: 40px;
  border-radius: var(--r-md);
  background: rgba(74, 108, 247, 0.12);
  display: grid;
  place-items: center;
  color: var(--clr-blue-light);
  flex-shrink: 0;
}

.contact-item__icon svg {
  width: 18px;
  height: 18px;
}

.contact-item__label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--clr-text-dim);
  margin-bottom: 0.2rem;
}

.contact-item__value {
  font-size: 0.95rem;
  color: var(--clr-text-muted);
  line-height: 1.6;
}

.contact-item__value--link {
  color: var(--clr-blue-light);
  transition: color 0.2s;
}

.contact-item__value--link:hover {
  color: var(--clr-white);
}

/* Contact Form */
.contact-form-wrap {
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  border-radius: var(--r-xl);
  padding: 2.25rem;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--clr-text-muted);
}

.form-label span {
  color: var(--clr-blue-light);
}

.form-input {
  background: var(--clr-surface-2);
  border: 1.5px solid var(--clr-border);
  border-radius: var(--r-md);
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--clr-text);
  transition: border-color 0.2s, box-shadow 0.2s;
  width: 100%;
  resize: vertical;
}

.form-input::placeholder {
  color: var(--clr-text-dim);
}

.form-input:focus {
  outline: none;
  border-color: var(--clr-blue);
  box-shadow: 0 0 0 3px rgba(74, 108, 247, 0.15);
}

.form-textarea {
  min-height: 120px;
}

.form-error {
  font-size: 0.8rem;
  color: #f87171;
}

/* Alerts */
.alert {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-radius: var(--r-md);
  margin-bottom: 2rem;
  font-size: 0.95rem;
  font-weight: 500;
}

.alert svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.alert--success {
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #4ade80;
}

.alert--error {
  background: rgba(248, 113, 113, 0.1);
  border: 1px solid rgba(248, 113, 113, 0.3);
  color: #f87171;
}

/* ── Footer ─────────────────────────────────────────────────── */
.site-footer {
  background: #080a14;
  border-top: 1px solid var(--clr-border);
  padding-block: 2.5rem;
}

.footer-inner {
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 3rem);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.footer-name {
  font-weight: 700;
  color: var(--clr-white);
  font-size: 0.95rem;
}

.footer-tagline {
  font-size: 0.8rem;
  color: var(--clr-text-dim);
}

.footer-links {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.footer-links a {
  font-size: 0.85rem;
  color: var(--clr-text-dim);
  transition: color 0.2s;
}

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

.footer-copy {
  font-size: 0.8rem;
  color: var(--clr-text-dim);
  width: 100%;
  text-align: center;
  padding-top: 1rem;
  border-top: 1px solid var(--clr-border);
}

/* ── Animations ─────────────────────────────────────────────── */
.fade-in {
  animation: fadeIn 1s var(--ease) both;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(24px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

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

.reveal:nth-child(2) {
  transition-delay: 0.1s;
}

.reveal:nth-child(3) {
  transition-delay: 0.2s;
}

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .ai-pillars {
    grid-template-columns: 1fr;
  }

  .ai-or {
    flex-direction: row;
    padding-top: 0;
    padding-inline: 1rem;
  }

  .ai-or::before,
  .ai-or::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--clr-border);
  }

  .portfolio-card {
    grid-template-columns: 1fr;
  }

  .portfolio-card--reverse {
    direction: ltr;
  }

  .portfolio-card__info {
    padding: 0 2rem 2rem !important;
  }

  .portfolio-card__visual {
    aspect-ratio: 16/7;
  }
}

@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: fixed;
    inset: var(--nav-h) 0 auto 0;
    flex-direction: column;
    background: rgba(13, 15, 26, 0.98);
    backdrop-filter: blur(16px);
    padding: 1.5rem;
    gap: 0.25rem;
    transform: translateY(-120%);
    transition: transform 0.35s var(--ease);
    z-index: 999;
    border-bottom: 1px solid var(--clr-border);
  }

  .nav-links.open {
    transform: translateY(0);
  }

  .nav-link {
    width: 100%;
    padding: 0.75rem 1rem;
  }

  .nav-link.nav-cta {
    margin-left: 0;
    margin-top: 0.5rem;
    text-align: center;
  }

  .contact-layout {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    justify-content: center;
    text-align: center;
  }

  .footer-links {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .btn {
    text-align: center;
    justify-content: center;
  }

  .btn {
    padding: 0.8rem 1.5rem;
  }
}

/* ── Spin animation (form submit) ───────────────────────────── */
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.spin {
  animation: spin 0.8s linear infinite;
  width: 1.1em;
  height: 1.1em;
}

/* ── Active nav link ─────────────────────────────────────────── */
.nav-link.active {
  color: var(--clr-white);
  background: rgba(255, 255, 255, 0.06);
}

/* ── Portfolio logo card ─────────────────────────────────────── */
.portfolio-card__visual--logo {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
  padding: 2.5rem;
}

.portfolio-hexxy-logo {
  width: 100%;
  max-width: 260px;
  height: auto;
  margin: auto;
  border-radius: var(--r-lg);
  object-fit: contain;
  filter: drop-shadow(0 0 40px rgba(74, 108, 247, 0.4));
}

/* ── Hexxy Chat Widget ───────────────────────────────────────── */
.hexxy-widget {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 9000;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.75rem;
}

.hexxy-toggle {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--clr-blue);
  color: var(--clr-white);
  border: none;
  border-radius: 999px;
  padding: 0.6rem 1.1rem 0.6rem 0.6rem;
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow: 0 8px 32px rgba(74, 108, 247, 0.45);
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
  position: relative;
}

.hexxy-toggle:hover {
  background: var(--clr-blue-light);
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(74, 108, 247, 0.55);
}

.hexxy-toggle-logo {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.hexxy-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--clr-green);
  border: 2px solid var(--clr-bg);
  animation: pulse-dot 2s ease-in-out infinite;
}

.hexxy-panel {
  width: 360px;
  max-height: 520px;
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  border-radius: var(--r-xl);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
  z-index: 10;
  animation: slideUp 0.25s var(--ease-spring) both;
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(16px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.hexxy-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.1rem;
  border-bottom: 1px solid var(--clr-border);
  background: var(--clr-surface-2);
  position: relative;
  z-index: 15;
  flex-shrink: 0;
}

.hexxy-header-logo {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.hexxy-header-name {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--clr-white);
}

.hexxy-header-sub {
  font-size: 0.75rem;
  color: var(--clr-text-dim);
}

.hexxy-close {
  margin-left: auto;
  background: transparent;
  border: none;
  color: var(--clr-text-muted);
  font-size: 1.4rem;
  line-height: 1;
  /* Large enough touch target for mobile (44×44px min) */
  min-width: 44px;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-sm);
  cursor: pointer;
  position: relative;
  z-index: 20;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  transition: color 0.2s, background 0.2s;
}

.hexxy-close:hover {
  color: var(--clr-white);
  background: rgba(255, 255, 255, 0.08);
}

.hexxy-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  scroll-behavior: smooth;
}

.hexxy-msg {
  max-width: 85%;
  padding: 0.6rem 0.875rem;
  border-radius: var(--r-md);
  font-size: 0.875rem;
  line-height: 1.6;
}

.hexxy-msg--bot {
  background: rgba(74, 108, 247, 0.15);
  border: 1px solid rgba(74, 108, 247, 0.2);
  color: var(--clr-text);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}

.hexxy-msg--user {
  background: var(--clr-blue);
  color: var(--clr-white);
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

.hexxy-msg--typing {
  background: rgba(74, 108, 247, 0.1);
  border: 1px solid rgba(74, 108, 247, 0.15);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 0.65rem 0.9rem;
}

.hexxy-msg--typing span {
  display: block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--clr-blue-light);
  opacity: 0.6;
  animation: hexxyDot 1.2s ease-in-out infinite;
}

.hexxy-msg--typing span:nth-child(2) { animation-delay: 0.2s; }
.hexxy-msg--typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes hexxyDot {
  0%, 80%, 100% { transform: scale(0.7); opacity: 0.4; }
  40%           { transform: scale(1);   opacity: 1; }
}

.hexxy-msg p { margin: 0; }

.hexxy-limit-bar {
  padding: 0.35rem 1rem;
  font-size: 0.72rem;
  color: var(--clr-text-dim);
  border-top: 1px solid var(--clr-border);
  text-align: right;
}

.hexxy-input-row {
  display: flex;
  gap: 0.5rem;
  padding: 0.75rem;
  border-top: 1px solid var(--clr-border);
}

.hexxy-input {
  flex: 1;
  background: var(--clr-surface-2);
  border: 1.5px solid var(--clr-border);
  border-radius: var(--r-md);
  padding: 0.55rem 0.875rem;
  font-size: 0.875rem;
  font-family: inherit;
  color: var(--clr-text);
  transition: border-color 0.2s;
}

.hexxy-input::placeholder { color: var(--clr-text-dim); }
.hexxy-input:focus { outline: none; border-color: var(--clr-blue); }

.hexxy-send {
  width: 38px;
  height: 38px;
  border-radius: var(--r-md);
  background: var(--clr-blue);
  border: none;
  color: var(--clr-white);
  display: grid;
  place-items: center;
  flex-shrink: 0;
  transition: background 0.2s;
}

.hexxy-send:hover { background: var(--clr-blue-light); }
.hexxy-send:disabled { opacity: 0.5; cursor: not-allowed; }

.hexxy-send svg {
  width: 16px;
  height: 16px;
}

@media (max-width: 640px) {
  /* Widget sits closer to the corner */
  .hexxy-widget {
    right: 1rem;
    bottom: 1rem;
  }

  /* Shrink toggle to a compact logo-only bubble */
  .hexxy-toggle {
    width: 52px;
    height: 52px;
    padding: 0;
    border-radius: 50%;
    justify-content: center;
  }

  /* Hide the "Ask Hexxy" label on mobile */
  .hexxy-toggle-label {
    display: none;
  }

  /* Scale logo to fill the button */
  .hexxy-toggle-logo {
    width: 36px;
    height: 36px;
  }

  /* Panel fills most of the screen width.
     Use dvh (dynamic viewport height) so the panel shrinks when the Android
     soft keyboard opens — without this the input row slides behind the keyboard.
     Fall back to 70vh for older browsers that don't support dvh. */
  .hexxy-panel {
    width: calc(100vw - 2rem);
    max-height: 70vh;           /* fallback */
    max-height: 70dvh;          /* shrinks with keyboard on Android/iOS */
    overflow: visible;          /* let children control their own overflow;
                                   avoids Android touch-intercept bug inside
                                   position:fixed + overflow:hidden stacks */
  }

  /* Ensure the messages area is still scrollable */
  .hexxy-messages {
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* Keep input font-size at 16px to prevent iOS zoom on focus
     (Android doesn't zoom but it's harmless there) */
  .hexxy-input {
    font-size: 1rem;
  }
}