@import url("https://fonts.cdnfonts.com/css/thegoodmonolith");

@font-face {
  font-family: "PP Neue Montreal";
  src: url("https://fonts.cdnfonts.com/s/64587/PPNeueMontreal-Medium.woff2")
    format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

/* ===== CSS VARIABLES ===== */
:root {
  /* Colors */
  --color-bg: #111111;
  --color-text: #ffffff;
  --color-text-muted: rgba(255, 255, 255, 0.7);
  --color-text-dim: rgba(255, 255, 255, 0.6);
  --color-dot: #444;
  --color-star: rgba(209, 255, 255, 1);
  /* Typography */
  --font-body: "TheGoodMonolith", sans-serif;
  --font-title: "PP Neue Montreal", sans-serif;
  --font-size-base: 0.75rem;
  --font-size-h2: 2rem;
  --font-size-h1: 3rem;
  --letter-spacing-title: -0.03em;
  --line-height: 1.4;
  /* Spacing */
  --spacing-base: 1rem;
  --spacing-sm: 0.75rem;
  --spacing-xs: 0.25rem;
  --spacing-md: 1.5rem;
  --spacing-lg: 2rem;
  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-medium: 0.3s ease;
  --transition-slow: 0.8s ease;
  /* Effects */
  --blur-amount: 5px;
}

/* ===== RESET & BASE STYLES ===== */
*,
*:before,
*:after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body, a, button, .nav-toggle, .dropdown-button, .slider-dot, .ai-badge {
  cursor: none;
}
body {
  font-family: var(--font-body);
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: var(--line-height);
  margin: 0;
  font-size: var(--font-size-base);
  overflow-x: hidden;
  cursor: none;
}

.water-cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(94, 194, 255, 0.95);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 9999;
  mix-blend-mode: screen;
  transition: transform 0.08s ease, opacity 0.2s ease, width 0.2s ease, height 0.2s ease;
}

.water-cursor.water-click {
  transform: translate(-50%, -50%) scale(1.25);
  opacity: 0.8;
}

.water-drop {
  position: fixed;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 2px solid rgba(94, 194, 255, 0.9);
  box-shadow: 0 0 0 0 rgba(94, 194, 255, 0.5);
  transform: translate(-50%, -50%) scale(0.2);
  opacity: 0.95;
  pointer-events: none;
  z-index: 9998;
  animation: waterDrop 0.7s ease-out forwards;
}

.water-trail {
  position: fixed;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(94, 194, 255, 0.85);
  box-shadow: 0 0 16px rgba(94, 194, 255, 0.22);
  transform: translate(-50%, -50%) scale(1);
  opacity: 0.9;
  pointer-events: none;
  z-index: 9998;
  animation: waterTrail 0.6s ease-out forwards;
}

@keyframes waterDrop {
  0% {
    transform: translate(-50%, -50%) scale(0.2);
    opacity: 0.95;
    box-shadow: 0 0 0 0 rgba(94, 194, 255, 0.45);
  }
  60% {
    transform: translate(-50%, -50%) scale(1.8);
    opacity: 0.5;
    box-shadow: 0 0 0 18px rgba(94, 194, 255, 0.12);
  }
  100% {
    transform: translate(-50%, -50%) scale(2.6);
    opacity: 0;
    box-shadow: 0 0 0 24px rgba(94, 194, 255, 0);
  }
}

@keyframes waterTrail {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.9;
  }
  100% {
    transform: translate(-50%, -50%) scale(1.8);
    opacity: 0;
  }
}

/* Dust/Scratches background effect for the entire site */
body::after {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("./images/white-dut-scratches-black-background_279525-2.avif");
  background-repeat: repeat;
  opacity: 0.05;
  mix-blend-mode: screen;
  pointer-events: none;
  z-index: 1;
}
h2,
h3 {
  font-weight: normal;
  margin-bottom: var(--spacing-sm);
}

h2 {
  font-family: var(--font-title);
  font-size: var(--font-size-h2);
  letter-spacing: var(--letter-spacing-title);
  text-transform: uppercase;
  margin-bottom: var(--spacing-md);
}

p {
  margin-bottom: var(--spacing-xs);
  opacity: 0.7;
}

ul {
  list-style: none;
}

/* ===== INTERACTIVE ELEMENTS ===== */
/* Global link style with hover effect */
a,
.links span {
  position: relative;
  cursor: pointer;
  color: var(--color-text);
  padding: 0;
  display: inline-block;
  z-index: 1;
  text-decoration: none;
  font-size: var(--font-size-base);
  opacity: 0.7;
  transition: color var(--transition-medium);
}

a::after,
.links span::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 100%;
  background-color: var(--color-text);
  z-index: -1;
  transition: width 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

a:hover::after,
.links span:hover::after {
  width: 100%;
}

a:hover,
.links span:hover {
  color: black;
  mix-blend-mode: difference;
  opacity: 1;
}

/* ===== LAYOUT COMPONENTS ===== */
.site-header {
  position: sticky;
  top: 20px;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 28px;
  width: min(100%, 1180px);
  margin: 0 auto;
  background: rgba(10, 14, 26, 0);
  /* border: 1px solid rgba(255, 255, 255, 0.08); */
  border-radius: 15px;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.site-brand a {
  font-size: 1.05rem;
  font-weight: 900;
  letter-spacing: 0.18em;
  color: var(--text);
  position: relative;
  text-decoration: none;
  transition: color 0.25s ease;
  animation: brandPulse 8s ease-in-out infinite;
}

.site-brand a::before {
  content: "";
  position: absolute;
  left: -10px;
  top: 50%;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent-soft);
  transform: translateY(-50%) scale(0.85);
  opacity: 0.9;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.site-brand a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.site-brand a:hover,
.site-brand a:focus-visible {
  color: var(--accent);
}

.site-brand a:hover::before,
.site-brand a:focus-visible::before {
  transform: translateY(-50%) scale(1.05);
  opacity: 1;
}

.site-brand a:hover::after,
.site-brand a:focus-visible::after {
  transform: scaleX(1);
  opacity: 1;
}
.nav-toggle {
  display: none;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  padding: 10px 14px;
  border-radius: 10px;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.site-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.site-nav a,
.dropdown {
  display: inline-flex;
  align-items: center;
}

.site-nav a,
.dropdown,
.nav-action {
  display: inline-flex;
  align-items: center;
}

.site-nav a {
  display: inline-block;
  padding: 10px 0;
  color: var(--muted);
}

.site-nav a + a,
.dropdown + a,
.site-nav a + .dropdown,
.site-nav a + .nav-action,
.dropdown + .nav-action {
  margin-left: 28px;
}
.nav-action {
  border: 1px solid rgba(94, 194, 255, 0.24);
  color: var(--text);
  background: rgba(94, 194, 255, 0.12);
  padding: 12px 18px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.25s ease, color 0.25s ease;
}

.nav-action:hover,
.nav-action:focus-visible {
  background: rgba(94, 194, 255, 0.24);
  transform: translateY(-1px);
}
.hero-section {
  top:-150px;
  width: 100%;
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Grid column assignments */
.nav {
  grid-column: 1 / span 3;
}

.values {
  grid-column: 5 / span 2;
}

.location-2 {
  grid-column: 7 / span 2;
}

.contact {
  grid-column: 9 / span 2;
}

.social {
  grid-column: 11 / span 2;
  text-align: right;
}

/* Bottom bar */
.bottom-bar {
  margin-top: auto;
  padding-top: var(--spacing-lg);
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  column-gap: var(--spacing-base);
  align-items: flex-end;
  width: 100%;
  position: relative;
  z-index: 5;
}

.coordinates {
  grid-column: 1 / span 3;
  opacity: var(--color-text-dim);
}

.links {
  grid-column: 5 / span 4;
  text-align: center;
}

.info {
  grid-column: 9 / span 4;
  text-align: right;
  opacity: var(--color-text-dim);
}

.links span {
  margin: 0 var(--spacing-base);
}

/* ===== LOGO COMPONENT ===== */
.logo-container {
  margin-bottom: var(--spacing-md);
  display: block;
  width: 3rem;
  height: 1.5rem;
  position: relative;
}

.logo-circles {
  position: relative;
  width: 100%;
  height: 100%;
}

.circle {
  position: absolute;
  border-radius: 50%;
  transition: transform var(--transition-medium);
  width: 1.4rem;
  height: 1.4rem;
  background-color: var(--color-text);
  top: 50%;
}

.circle-1 {
  left: 0;
  transform: translate(0, -50%);
}

.circle-2 {
  left: 0.8rem;
  transform: translate(0, -50%);
  mix-blend-mode: exclusion;
}

.logo-container:hover .circle-1 {
  transform: translate(-0.5rem, -50%);
}
.site-footer {
  text-align: center;
  padding: 28px 28px 40px;
  color: var(--muted);
}
.logo-container:hover .circle-2 {
  transform: translate(0.5rem, -50%);
}
.ai-badge {
  position: fixed;
  right: 24px;
  bottom: 24px;
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 14px 16px;
  border-radius: 999px;
  background: rgba(8, 12, 22, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 25px 45px rgba(0, 0, 0, 0.18);
  z-index: 45;
  cursor: pointer;
  transition: transform 180ms ease, background 180ms ease, box-shadow 180ms ease;
}
.ai-badge:hover,
.ai-badge:focus-visible {
  transform: translateY(-2px);
  background: rgba(8, 12, 22, 1);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.24);
}

.badge-tooltip {
  position: absolute;
  right: 8px;
  bottom: calc(100% + 10px);
  background: rgba(8,12,22,0.98);
  color: var(--text);
  padding: 8px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.06);
  font-size: 0.85rem;
  white-space: nowrap;
  opacity: 0;
  transform: translateY(6px) scale(0.98);
  transition: opacity 160ms ease, transform 160ms ease;
  pointer-events: none;
  z-index: 40;
}

.ai-badge:hover .badge-tooltip,
.ai-badge:focus-visible .badge-tooltip {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

/* subtle pulse behind the badge on hover */
.ai-badge::after {
  content: "";
  position: absolute;
  right: 50%;
  bottom: 50%;
  width: 56px;
  height: 56px;
  transform: translate(50%, 50%) scale(0.9);
  border-radius: 50%;
  background: rgba(94, 194, 255, 0.06);
  opacity: 0;
  transition: transform 260ms ease, opacity 260ms ease;
  pointer-events: none;
  z-index: 10;
}

.ai-badge:hover::after,
.ai-badge:focus-visible::after {
  opacity: 1;
  transform: translate(50%, 50%) scale(1.25);
}
.badge-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}

.badge-icon svg {
  width: 18px;
  height: 18px;
  display: block;
  color: var(--text);
}

/* small scale on the svg icon for tactile feedback */
.ai-badge .badge-icon svg {
  transition: transform 220ms cubic-bezier(.2,.9,.2,1);
}

.ai-badge:hover .badge-icon svg,
.ai-badge:focus-visible .badge-icon svg {
  transform: scale(1.08);
}

.badge-label {
  display: inline-flex;
}

.ai-popup,
.ai-backdrop {
  position: fixed;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  z-index: 35;
}

.ai-popup {
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  padding: 20px;
}

.ai-popup-inner {
  width: min(360px, calc(100% - 40px));
  background: rgba(8, 12, 22, 0.98);
  border: 1px solid rgba(94, 194, 255, 0.3);
  border-radius: 24px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
  overflow: hidden;
}

.ai-popup-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 22px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.ai-popup-title {
  display: block;
  font-size: 1rem;
  font-weight: 800;
}

.ai-popup-subtitle {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.ai-popup-close {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text);
  font-size: 1.2rem;
  cursor: pointer;
}

.ai-popup-body {
  padding: 22px;
}

.ai-popup-messages {
  display: grid;
  gap: 12px;
  margin-bottom: 18px;
  max-height: 240px;
  overflow-y: auto;
}

.ai-message {
  padding: 14px 16px;
  border-radius: 18px;
  font-size: 0.95rem;
  line-height: 1.6;
}

.ai-message--assistant {
  background: rgba(94, 194, 255, 0.12);
  border: 1px solid rgba(94, 194, 255, 0.18);
  color: var(--text);
  align-self: flex-start;
}

.ai-message--user {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text);
  align-self: flex-end;
}

.ai-popup-form {
  display: grid;
  gap: 12px;
}

.ai-popup-label {
  font-size: 0.85rem;
  color: var(--muted);
}

.ai-popup-input-wrap {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
}

.ai-popup-input {
  width: 100%;
  min-height: 50px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  border-radius: 16px;
}

.ai-popup-input:focus {
  outline: 2px solid rgba(94, 194, 255, 0.45);
  outline-offset: 2px;
}

.ai-popup-submit {
  min-width: 90px;
  padding: 0 18px;
}

.ai-backdrop {
  background: rgba(0, 0, 0, 0.45);
}

.ai-popup.open,
.ai-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

@media (max-width: 720px) {
  .ai-badge {
    right: 16px;
    bottom: 16px;
    min-width: 50px;
    min-height: 50px;
    border-radius: 18px;
    padding: 0 12px;
  }
}

/* ===== DOT GRID ===== */
.dot-grid {
  width: 100%;
  height: 150px;
  position: relative;
  margin-top: var(--spacing-base);
  overflow: hidden;
  z-index: 1;
}

.dot {
  position: absolute;
  font-size: 10px;
  color: var(--color-dot);
  transition: all var(--transition-fast);
  will-change: transform, color;
}

/* ===== WEBGL SECTION ===== */
.sticky-container {
  position: relative;
  height: 500vh;
  width: 100%;
  margin: 0;
}

.webgl-section {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 10;
  overflow: hidden;
  will-change: transform, opacity, filter;
}

.canvas-container {
  width: 100%;
  height: 100%;
  position: relative;
  will-change: transform, opacity, filter;
  display: flex;
  justify-content: center;
  align-items: center;
}

canvas#space {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
}

/* ===== ANIMATED TEXT ===== */
.animated-text {
  position: absolute;
  top: auto;
  left: 50%;
  transform: translate(-50%, calc(-50% + 40px));
  color: var(--color-text);
  font-family: var(--font-title);
  font-size: var(--font-size-h1);
  text-align: center;
  opacity: 0;
  z-index: 20;
  text-transform: uppercase;
  letter-spacing: var(--letter-spacing-title);
  pointer-events: none;
  width: 80%;
  max-width: 800px;
  will-change: opacity, transform, filter;
  filter: blur(8px);
  transition: filter 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ===== ADDITIONAL SECTION ===== */
.additional-section {
  width: 100%;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: var(--spacing-lg);
  position: relative;
  z-index: 20;
  overflow: hidden;
}

.additional-content {
  max-width: 800px;
  text-align: center;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity var(--transition-slow), transform var(--transition-slow);
}

.additional-content.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Reduced width for paragraphs */
.additional-content p {
  font-size: 1rem;
  line-height: 1.6;
  opacity: 0.8;
  margin-bottom: var(--spacing-base);
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

.section-transition {
  position: relative;
  overflow: hidden;
}
@media (max-width: 720px) {
  .site-header {
    padding: 18px 18px;
  }

  .site-nav {
    display: none;
    flex-direction: column;
    width: 100%;
    margin-top: 16px;
    padding: 18px 16px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(10, 14, 26, 0.84);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.2);
  }

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

  .site-nav a {
    margin-bottom: 12px;
    padding: 12px 0;
    border-radius: 16px;
    transition: background 0.25s ease, color 0.25s ease;
  }

  .site-nav a:hover,
  .site-nav a:focus-visible {
    background: rgba(94, 194, 255, 0.08);
    color: var(--text);
  }

  .nav-toggle {
    display: inline-flex;
  }
}
