/* ===============================================
   INDUS CUP 2K26 - MAIN STYLESHEET
   Global Styles, Design System & Theme Variables
   =============================================== */

/* ===============================================
   CUSTOM FONTS - Edo SZ by Vic Fieger
   =============================================== */

@font-face {
  font-family: 'Edo SZ';
  src: url('../assets/fonts/edosz.woff2') format('woff2'),
       url('../assets/fonts/edosz.woff') format('woff'),
       url('../assets/fonts/edosz.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

/* Fallback web font alternative if local Edo SZ not available */
@import url('https://fonts.googleapis.com/css2?family=Bungee&display=swap');

/* CSS Variables - Design System */
:root {
  /* Primary Brand Colors */
  --primary-color: #FF6B35;      /* Energetic Orange - Bold & dynamic */
  --secondary-color: #F7B801;     /* Vibrant Yellow - High energy */
  --accent-start: #F7B801;       /* Yellow start */
  --accent-end: #FF6B35;         /* Orange end gradient */
  --highlight-blue: #E63946;     /* Hot Red - Intense */
  --white: #FFFFFF;
  --black: #0A0A0A;

  /* Extended Color Palette */
  --gray-100: #F8F9FA;
  --gray-200: #E9ECEF;
  --gray-300: #DEE2E6;
  --gray-400: #CED4DA;
  --gray-500: #6C757D;
  --gray-600: #495057;
  --gray-700: #343A40;
  --gray-800: #212529;
  --gray-900: #0A0A0A;

  /* Gradient Combinations */
  --gradient-primary: linear-gradient(135deg, #FF6B35 0%, #E63946 100%);
  --gradient-secondary: linear-gradient(135deg, #F7B801 0%, #FF6B35 100%);
  --gradient-accent: linear-gradient(135deg, #F7B801 0%, #FF6B35 100%);
  --gradient-hero: linear-gradient(135deg, #E63946 0%, #FF6B35 50%, #F7B801 100%);

  /* Typography Scale - Edo SZ brush/graffiti style font */
  --font-primary: 'Edo SZ', 'Bungee', cursive;  /* Brush/graffiti style for main title */
  --font-heading: 'Edo SZ', 'Bungee', cursive;  /* Same for all headings */
  --font-secondary: 'Poppins', sans-serif;      /* Subheadings & body */
  --font-tertiary: 'Inter', sans-serif;         /* UI labels & small text */

  /* Font Sizes - Fluid Typography */
  --fs-hero: clamp(3rem, 8vw, 6rem);           /* 48px - 96px */
  --fs-h1: clamp(2.5rem, 6vw, 4rem);           /* 40px - 64px */
  --fs-h2: clamp(2rem, 5vw, 3rem);             /* 32px - 48px */
  --fs-h3: clamp(1.5rem, 4vw, 2rem);           /* 24px - 32px */
  --fs-h4: clamp(1.25rem, 3vw, 1.5rem);        /* 20px - 24px */
  --fs-body: clamp(1rem, 2vw, 1.125rem);       /* 16px - 18px */
  --fs-small: clamp(0.875rem, 1.5vw, 1rem);    /* 14px - 16px */

  /* Font Weights */
  --fw-light: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;
  --fw-black: 900;

  /* Spacing Scale */
  --space-xs: 0.5rem;    /* 8px */
  --space-sm: 1rem;      /* 16px */
  --space-md: 1.5rem;    /* 24px */
  --space-lg: 2rem;      /* 32px */
  --space-xl: 3rem;      /* 48px */
  --space-2xl: 4rem;     /* 64px */
  --space-3xl: 6rem;     /* 96px */

  /* Container & Layout */
  --container-max: 1200px;
  --container-padding: var(--space-md);
  --section-padding: var(--space-3xl);

  /* Border Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 20px;
  --radius-full: 50%;

  /* Shadows */
  --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 15px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.15);
  --shadow-glow: 0 0 20px rgba(255, 164, 27, 0.4);

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;

  /* Z-index Scale */
  --z-dropdown: 1000;
  --z-sticky: 1020;
  --z-fixed: 1030;
  --z-modal: 1050;
  --z-popover: 1060;
  --z-tooltip: 1070;
}

/* ===============================================
   RESET & BASE STYLES
   =============================================== */

/* Box sizing reset */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Remove default margin and padding */
* {
  margin: 0;
  padding: 0;
}

/* HTML and Body */
html {
  scroll-behavior: smooth;
  font-size: 16px;
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
}

body {
  font-family: var(--font-secondary);
  font-size: var(--fs-body);
  font-weight: var(--fw-light);
  line-height: 1.6;
  color: var(--gray-800);
  background-color: var(--white);
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Improve media defaults */
img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}

/* Improve form elements */
input,
button,
textarea,
select {
  font: inherit;
}

/* Remove button styles */
button {
  background: none;
  border: none;
  cursor: pointer;
}

/* Improve link styles */
a {
  color: inherit;
  text-decoration: none;
}

/* Remove list styles */
ul,
ol {
  list-style: none;
}

/* ===============================================
   TYPOGRAPHY SYSTEM
   =============================================== */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-primary);
  font-weight: var(--fw-bold);
  line-height: 1.2;
  color: var(--primary-color);
  margin-bottom: var(--space-sm);
}

h1 {
  font-size: var(--fs-h1);
}

h2 {
  font-size: var(--fs-h2);
}

h3 {
  font-size: var(--fs-h3);
}

h4 {
  font-size: var(--fs-h4);
}

p {
  margin-bottom: var(--space-sm);
  color: var(--gray-700);
}

/* Special Typography Classes */
.text-primary { color: var(--primary-color); }
.text-secondary { color: var(--secondary-color); }
.text-accent { color: var(--accent-start); }
.text-white { color: var(--white); }
.text-muted { color: var(--gray-500); }

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.font-primary { font-family: var(--font-primary); }
.font-secondary { font-family: var(--font-secondary); }
.font-tertiary { font-family: var(--font-tertiary); }

.fw-light { font-weight: var(--fw-light); }
.fw-medium { font-weight: var(--fw-medium); }
.fw-semibold { font-weight: var(--fw-semibold); }
.fw-bold { font-weight: var(--fw-bold); }

/* ===============================================
   CONTAINER & LAYOUT UTILITIES
   =============================================== */

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

/* Section Styling */
section {
  padding: var(--section-padding) 0;
  position: relative;
}

.section__header {
  text-align: center;
  margin-bottom: var(--space-2xl);
}

.section__title {
  font-size: var(--fs-h2);
  color: var(--primary-color);
  margin-bottom: var(--space-sm);
  position: relative;
}

.section__title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: var(--gradient-accent);
  border-radius: var(--radius-sm);
}

.section__subtitle {
  font-size: var(--fs-body);
  color: var(--gray-600);
  font-weight: var(--fw-medium);
}

/* ===============================================
   BUTTON COMPONENT SYSTEM
   =============================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  padding: var(--space-sm) var(--space-lg);
  font-family: var(--font-secondary);
  font-size: var(--fs-body);
  font-weight: var(--fw-semibold);
  text-decoration: none;
  border: 2px solid transparent;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

/* Button Variants */
.btn--primary {
  background: var(--gradient-primary);
  color: var(--white);
  box-shadow: var(--shadow-md);
}

.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn--secondary {
  background: var(--gradient-secondary);
  color: var(--white);
  box-shadow: var(--shadow-md);
}

.btn--secondary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn--outline {
  background: var(--white);
  color: var(--primary-color);
  border-color: var(--primary-color);
  box-shadow: var(--shadow-sm);
}

.btn--outline:hover {
  background: var(--primary-color);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

/* Button Sizes */
.btn--large {
  padding: var(--space-md) var(--space-xl);
  font-size: var(--fs-h4);
}

.btn--small {
  padding: var(--space-xs) var(--space-sm);
  font-size: var(--fs-small);
}

.btn--full {
  width: 100%;
}

/* Button Effects */
.btn--glow {
  position: relative;
}

.btn--glow::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: var(--gradient-accent);
  border-radius: var(--radius-lg);
  z-index: -1;
  opacity: 0;
  transition: opacity var(--transition-base);
}

.btn--glow:hover::before {
  opacity: 1;
  animation: pulse-glow 2s infinite;
}

.btn__icon {
  font-size: 1.2em;
}

/* ===============================================
   FORM COMPONENTS
   =============================================== */

.form__group {
  margin-bottom: var(--space-md);
}

.form__input,
.form__textarea,
.form__select {
  width: 100%;
  padding: var(--space-sm);
  border: 2px solid var(--gray-300);
  border-radius: var(--radius-md);
  font-family: var(--font-secondary);
  font-size: var(--fs-body);
  transition: border-color var(--transition-base);
}

.form__input:focus,
.form__textarea:focus,
.form__select:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(27, 59, 115, 0.1);
}

.form__textarea {
  resize: vertical;
  min-height: 100px;
}

/* ===============================================
   UTILITY CLASSES
   =============================================== */

/* Display */
.d-none { display: none !important; }
.d-block { display: block !important; }
.d-flex { display: flex !important; }
.d-grid { display: grid !important; }

/* Flexbox Utilities */
.flex-center { 
  display: flex; 
  align-items: center; 
  justify-content: center; 
}

.flex-between { 
  display: flex; 
  align-items: center; 
  justify-content: space-between; 
}

.flex-column { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.align-center { align-items: center; }
.justify-center { justify-content: center; }

/* Spacing Utilities */
.mt-0 { margin-top: 0 !important; }
.mt-1 { margin-top: var(--space-xs) !important; }
.mt-2 { margin-top: var(--space-sm) !important; }
.mt-3 { margin-top: var(--space-md) !important; }
.mt-4 { margin-top: var(--space-lg) !important; }
.mt-5 { margin-top: var(--space-xl) !important; }

.mb-0 { margin-bottom: 0 !important; }
.mb-1 { margin-bottom: var(--space-xs) !important; }
.mb-2 { margin-bottom: var(--space-sm) !important; }
.mb-3 { margin-bottom: var(--space-md) !important; }
.mb-4 { margin-bottom: var(--space-lg) !important; }
.mb-5 { margin-bottom: var(--space-xl) !important; }

/* Position Utilities */
.position-relative { position: relative; }
.position-absolute { position: absolute; }
.position-fixed { position: fixed; }
.position-sticky { position: sticky; }

/* Border Radius */
.rounded-sm { border-radius: var(--radius-sm); }
.rounded-md { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-xl { border-radius: var(--radius-xl); }
.rounded-full { border-radius: var(--radius-full); }

/* ===============================================
   ACCESSIBILITY & MOTION
   =============================================== */

/* Focus indicators */
:focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  html {
    scroll-behavior: auto;
  }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  :root {
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 8px 15px rgba(0, 0, 0, 0.3);
  }
}

/* ===============================================
   RESPONSIVE DESIGN - MOBILE FIRST
   =============================================== */

/* Tablet styles */
@media screen and (min-width: 768px) {
  :root {
    --container-padding: var(--space-xl);
    --section-padding: var(--space-3xl);
  }
}

/* Desktop styles */
@media screen and (min-width: 1024px) {
  :root {
    --container-padding: var(--space-2xl);
  }
}

/* Large desktop styles */
@media screen and (min-width: 1440px) {
  :root {
    --container-max: 1400px;
  }
}