/* ========================================
   4i4A Group - Step 2: Safe Layout System
   Gradual Migration - Layout Utilities Only
   ======================================== */

/* ===== ADDITIONAL LAYOUT VARIABLES ===== */
:root {
  /* Grid utilities (new, won't conflict) */
  --grid-cols-1: repeat(1, 1fr);
  --grid-cols-2: repeat(2, 1fr);
  --grid-cols-3: repeat(3, 1fr);
  --grid-cols-auto: repeat(auto-fit, minmax(200px, 1fr));
  
  /* Container sizes (new, won't conflict) */
  --container-xs: 320px;
  --container-sm: 640px;
  --container-md: 768px;
  --container-lg: 1024px;
  --container-xl: 1280px;
  
  /* Border radius scale (new, won't conflict) */
  --radius-none: 0;
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 8px;
  --radius-xl: 12px;
  --radius-2xl: 16px;
  --radius-full: 50%;
  
  /* Shadow scale (new, won't conflict) */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 25px rgba(0, 0, 0, 0.25);
  --shadow-xl: 0 15px 50px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 10px var(--electric-cyan), 0 0 20px rgba(0, 255, 255, 0.3);
}

/* ===== SAFE LAYOUT UTILITIES (prefixed with u-) ===== */

/* Display utilities */
.u-block { display: block !important; }
.u-inline-block { display: inline-block !important; }
.u-inline { display: inline !important; }
.u-grid { display: grid !important; }
.u-inline-grid { display: inline-grid !important; }
.u-hidden { display: none !important; }

/* Flexbox utilities (enhanced) */
.u-flex-wrap { flex-wrap: wrap !important; }
.u-flex-nowrap { flex-wrap: nowrap !important; }
.u-flex-1 { flex: 1 !important; }
.u-flex-auto { flex: auto !important; }
.u-flex-none { flex: none !important; }
.u-flex-shrink-0 { flex-shrink: 0 !important; }
.u-flex-grow { flex-grow: 1 !important; }

/* Justify content */
.u-justify-start { justify-content: flex-start !important; }
.u-justify-end { justify-content: flex-end !important; }
.u-justify-around { justify-content: space-around !important; }
.u-justify-evenly { justify-content: space-evenly !important; }

/* Align items */
.u-items-start { align-items: flex-start !important; }
.u-items-end { align-items: flex-end !important; }
.u-items-stretch { align-items: stretch !important; }
.u-items-baseline { align-items: baseline !important; }

/* Grid utilities */
.u-grid-cols-1 { grid-template-columns: var(--grid-cols-1) !important; }
.u-grid-cols-2 { grid-template-columns: var(--grid-cols-2) !important; }
.u-grid-cols-3 { grid-template-columns: var(--grid-cols-3) !important; }
.u-grid-cols-auto { grid-template-columns: var(--grid-cols-auto) !important; }

/* Position utilities */
.u-relative { position: relative !important; }
.u-absolute { position: absolute !important; }
.u-fixed { position: fixed !important; }
.u-sticky { position: sticky !important; }
.u-static { position: static !important; }

/* Width utilities */
.u-w-auto { width: auto !important; }
.u-w-full { width: 100% !important; }
.u-w-1\/2 { width: 50% !important; }
.u-w-1\/3 { width: 33.333333% !important; }
.u-w-2\/3 { width: 66.666667% !important; }
.u-w-1\/4 { width: 25% !important; }
.u-w-3\/4 { width: 75% !important; }

/* Height utilities */
.u-h-auto { height: auto !important; }
.u-h-full { height: 100% !important; }
.u-h-screen { height: 100vh !important; }
.u-min-h-0 { min-height: 0 !important; }
.u-min-h-full { min-height: 100% !important; }
.u-min-h-screen { min-height: 100vh !important; }

/* Max width utilities */
.u-max-w-none { max-width: none !important; }
.u-max-w-full { max-width: 100% !important; }
.u-max-w-xs { max-width: var(--container-xs) !important; }
.u-max-w-sm { max-width: var(--container-sm) !important; }
.u-max-w-md { max-width: var(--container-md) !important; }
.u-max-w-lg { max-width: var(--container-lg) !important; }
.u-max-w-xl { max-width: var(--container-xl) !important; }

/* Overflow utilities */
.u-overflow-auto { overflow: auto !important; }
.u-overflow-hidden { overflow: hidden !important; }
.u-overflow-visible { overflow: visible !important; }
.u-overflow-scroll { overflow: scroll !important; }
.u-overflow-x-auto { overflow-x: auto !important; }
.u-overflow-x-hidden { overflow-x: hidden !important; }
.u-overflow-y-auto { overflow-y: auto !important; }
.u-overflow-y-hidden { overflow-y: hidden !important; }

/* Border radius utilities */
.u-rounded-none { border-radius: var(--radius-none) !important; }
.u-rounded-sm { border-radius: var(--radius-sm) !important; }
.u-rounded { border-radius: var(--radius-md) !important; }
.u-rounded-lg { border-radius: var(--radius-lg) !important; }
.u-rounded-xl { border-radius: var(--radius-xl) !important; }
.u-rounded-2xl { border-radius: var(--radius-2xl) !important; }
.u-rounded-full { border-radius: var(--radius-full) !important; }

/* Shadow utilities */
.u-shadow-none { box-shadow: none !important; }
.u-shadow-sm { box-shadow: var(--shadow-sm) !important; }
.u-shadow { box-shadow: var(--shadow-md) !important; }
.u-shadow-lg { box-shadow: var(--shadow-lg) !important; }
.u-shadow-xl { box-shadow: var(--shadow-xl) !important; }
.u-shadow-glow { box-shadow: var(--shadow-glow) !important; }

/* Box sizing */
.u-box-border { box-sizing: border-box !important; }
.u-box-content { box-sizing: content-box !important; }

/* ===== RESPONSIVE UTILITIES ===== */

/* Mobile-first responsive utilities */
@media (min-width: 640px) {
  .sm\:u-flex { display: flex !important; }
  .sm\:u-grid { display: grid !important; }
  .sm\:u-hidden { display: none !important; }
  .sm\:u-grid-cols-2 { grid-template-columns: var(--grid-cols-2) !important; }
  .sm\:u-grid-cols-3 { grid-template-columns: var(--grid-cols-3) !important; }
}

@media (min-width: 768px) {
  .md\:u-flex { display: flex !important; }
  .md\:u-grid { display: grid !important; }
  .md\:u-hidden { display: none !important; }
  .md\:u-grid-cols-2 { grid-template-columns: var(--grid-cols-2) !important; }
  .md\:u-grid-cols-3 { grid-template-columns: var(--grid-cols-3) !important; }
  .md\:u-flex-row { flex-direction: row !important; }
  .md\:u-flex-col { flex-direction: column !important; }
}

@media (min-width: 1024px) {
  .lg\:u-flex { display: flex !important; }
  .lg\:u-grid { display: grid !important; }
  .lg\:u-hidden { display: none !important; }
  .lg\:u-grid-cols-3 { grid-template-columns: var(--grid-cols-3) !important; }
}

/* ===== STEP 2 COMPLETE - SAFE LAYOUT UTILITIES READY ===== */
