@import url('https://fonts.googleapis.com/css2?family=Google+Sans+Flex:opsz,slnt,wdth,wght,ROND@8..144,-10..0,25..150,100..700,0..100&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Google+Sans+Code:ital,wght@0,400;0,500;1,400&display=swap');
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&display=swap');

/* =============================================
   koudd.lab — Design System & Main Styles
   Emmanuel Pirela © 2024
   ============================================= */
/* Google Sans Flex is the same variable font used by Google Antigravity */
/* Fallback chain: Google Sans Flex → DM Sans → system-ui */



/* ─── CSS VARIABLES ─── */
:root {
  /* Brand Colors */
  --orange:        #FF5500;
  --orange-glow:   #FF7733;
  --orange-dark:   #CC3300;
  --orange-dim:    rgba(255, 85, 0, 0.12);
  --orange-dim2:   rgba(255, 85, 0, 0.06);

  /* Neutrals */
  --black:         #050505;
  --black-2:       #0D0D0D;
  --black-3:       #111111;
  --black-4:       #181818;
  --black-5:       #222222;
  --white:         #FFFFFF;
  --white-90:      rgba(255,255,255,0.9);
  --white-60:      rgba(255,255,255,0.6);
  --white-30:      rgba(255,255,255,0.3);
  --white-10:      rgba(255,255,255,0.07);
  --white-05:      rgba(255,255,255,0.04);

  /* Glass */
  --glass-bg:      rgba(255, 85, 0, 0.04);
  --glass-border:  rgba(255, 85, 0, 0.18);
  --glass-hover:   rgba(255, 85, 0, 0.10);
  --glass-white:   rgba(255,255,255,0.05);

  /* Fonts — Google Sans Flex (as used on antigravity.google) */
  --font-main:     'Google Sans Flex', 'DM Sans', system-ui, sans-serif;
  --font-mono:     'Google Sans Code', 'Courier New', monospace;
  --font-display:  'Google Sans Flex', 'DM Sans', system-ui, sans-serif;

  /* Spacing */
  --gap-xs:  0.5rem;
  --gap-sm:  1rem;
  --gap-md:  2rem;
  --gap-lg:  4rem;
  --gap-xl:  6rem;

  /* Transitions */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in:  cubic-bezier(0.7, 0, 0.84, 0);
  --spring:   cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Radius */
  --r-sm:  8px;
  --r-md:  16px;
  --r-lg:  24px;
  --r-xl:  32px;
  --r-full: 999px;

  /* Shadows */
  --shadow-orange: 0 0 30px rgba(255, 85, 0, 0.25);
  --shadow-orange-sm: 0 0 12px rgba(255, 85, 0, 0.3);
  --shadow-card: 0 8px 32px rgba(0,0,0,0.4);
  --shadow-glow: 0 0 60px rgba(255, 85, 0, 0.15), 0 0 120px rgba(255, 85, 0, 0.08);

  /* Nav height */
  --nav-h: 70px;
}

/* ─── RESET ─── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  min-width: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden !important;
  max-width: 100%;
}

body {
  font-family: var(--font-main);
  background: var(--black);
  color: var(--white);
  overflow-x: hidden !important;
  line-height: 1.6;
  max-width: 100%;
  min-height: 100vh;
  touch-action: pan-y;
  overscroll-behavior-x: contain;
}

section {
  overflow-x: hidden;
}

.container,
.nav-inner,
.hero-content,
.card,
.service-card,
.product-card,
.project-card,
.modal,
.form-row {
  min-width: 0;
}

*, *::before, *::after {
  min-width: 0;
}

img, video { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
ul, ol { list-style: none; }
input, textarea, select {
  font-family: inherit;
  outline: none;
}

::selection {
  background: var(--orange);
  color: var(--white);
}

/* Scrollbar */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--black-2); }
::-webkit-scrollbar-thumb { background: var(--orange); border-radius: 99px; }

/* ─── TYPOGRAPHY ─── */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.01em; /* Google Sans Flex has tighter natural spacing */
}

h1 { font-size: clamp(3rem, 8vw, 7rem); }
h2 { font-size: clamp(2.2rem, 5vw, 4rem); }
h3 { font-size: clamp(1.4rem, 3vw, 2rem); }
h4 { font-size: 1.2rem; }

p { color: var(--white-60); font-size: 1.05rem; line-height: 1.75; }

.mono { font-family: var(--font-mono); }

.text-orange { color: var(--orange); }
.text-white  { color: var(--white); }
.text-muted  { color: var(--white-60); }

/* ─── LAYOUT HELPERS ─── */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--gap-md);
}

.section {
  padding: var(--gap-xl) 0;
  position: relative;
}

.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-label {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--orange);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  display: block;
  margin-bottom: 1rem;
}

.section-title {
  margin-bottom: 1rem;
}

.section-desc {
  max-width: 600px;
  margin: 0 auto;
  color: var(--white-60);
}

/* ─── SECTION DIVIDER ─── */
.divider {
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, var(--orange), transparent);
  margin: 1.5rem auto;
  border-radius: 99px;
}

.divider.left {
  margin: 1.5rem 0;
}

/* ─── GRID ─── */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--gap-md); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap-md); }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap-md); }

/* ─── FLEX ─── */
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.gap-sm { gap: var(--gap-sm); }
.gap-md { gap: var(--gap-md); }

/* ─── BACKGROUND NOISE TEXTURE ─── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  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)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
  opacity: 0.35;
}

/* ─── ORANGE GLOW ORBS ─── */
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
}

.orb-1 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(255,85,0,0.12) 0%, transparent 70%);
  top: -100px;
  right: -100px;
}

.orb-2 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(255,85,0,0.08) 0%, transparent 70%);
  bottom: 0;
  left: -50px;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  :root { --gap-lg: 3rem; --gap-xl: 4rem; }
  .grid-2,
  .grid-3,
  .grid-4 { grid-template-columns: 1fr; }
  .container { padding: 0 1.25rem; }
}

/* ─── PRELOADER ─── */
#preloader {
  position: fixed;
  inset: 0;
  background: var(--black);
  z-index: 99999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  transition: opacity 0.6s var(--ease-out), visibility 0.6s;
}

#preloader.hidden {
  opacity: 0;
  visibility: hidden;
}

.preloader-logo {
  width: 80px;
  animation: preloader-pulse 1.5s ease-in-out infinite;
}

.preloader-bar {
  width: 200px;
  height: 2px;
  background: var(--black-5);
  border-radius: 99px;
  overflow: hidden;
}

.preloader-fill {
  height: 100%;
  background: var(--orange);
  border-radius: 99px;
  animation: preloader-fill 1.8s var(--ease-out) forwards;
}

@keyframes preloader-pulse {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 12px rgba(255,85,0,0.5)); }
  50%       { transform: scale(1.08); filter: drop-shadow(0 0 24px rgba(255,85,0,0.8)); }
}

@keyframes preloader-fill {
  0%   { width: 0%; }
  100% { width: 100%; }
}

/* ─── CURSOR GLOW ─── */
#cursor-glow {
  position: fixed;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,85,0,0.06) 0%, transparent 70%);
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  transition: transform 0.1s linear;
}
