_variables.scss 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214
  1. // ==========================================================================
  2. // VARIABLES
  3. // ==========================================================================
  4. @use 'sass:map';
  5. // Colors
  6. // -------------------------
  7. $colors: (
  8. 'primary': (
  9. 'base': #1e88e5, // Main blue as in "ITAgency"
  10. 'light': #64b5f6, // Lighter blue for hover
  11. 'dark': #072066, // Dark blue for backgrounds like hero
  12. 'gradient': linear-gradient(135deg, #1e88e5 0%, #0d47a1 100%)
  13. ),
  14. 'secondary': (
  15. 'base': #f5f5f5, // Grayish white for backgrounds
  16. 'light': #ffffff, // Pure white
  17. 'dark': #e0e0e0 // Light gray for borders and separators
  18. ),
  19. 'neutral': (
  20. 'light': #f5f5f5, // Very light gray
  21. 'base': #9e9e9e, // Medium gray
  22. 'dark': #424242, // Dark gray for secondary text
  23. 'darker': #000 // Almost black for main text
  24. ),
  25. 'accent': #2196f3 // Accent blue for highlights
  26. );
  27. // Direct color variables
  28. $primary: map.get(map.get($colors, 'primary'), 'base');
  29. $primary-light: map.get(map.get($colors, 'primary'), 'light');
  30. $primary-dark: map.get(map.get($colors, 'primary'), 'dark');
  31. $primary-gradient: map.get(map.get($colors, 'primary'), 'gradient');
  32. $white: map.get(map.get($colors, 'secondary'), 'light');
  33. $light-gray: map.get(map.get($colors, 'secondary'), 'dark');
  34. $gray: map.get(map.get($colors, 'neutral'), 'base');
  35. $dark-gray: map.get(map.get($colors, 'neutral'), 'dark');
  36. $black: map.get(map.get($colors, 'neutral'), 'darker');
  37. $accent: map.get($colors, 'accent');
  38. // Breakpoints
  39. $breakpoints: (
  40. 'xs': 0,
  41. 'sm': 576px,
  42. 'md': 1024px,
  43. 'md-c': 1025px,
  44. 'lg': 1280px,
  45. 'xl': 1440px,
  46. 'xxl': 1600px
  47. );
  48. // Spacing
  49. $spacers: (
  50. 0: 0,
  51. 1: 0.25rem, // 4px
  52. 2: 0.5rem, // 8px
  53. 3: 1rem, // 16px
  54. 4: 1.5rem, // 24px
  55. 5: 3rem, // 48px
  56. 6: 4rem, // 64px
  57. 7: 5rem, // 80px
  58. 8: 6rem, // 96px
  59. 9: 8rem, // 128px
  60. 10: 10rem, // 160px
  61. 11: 12rem, // 192px
  62. 12: 15rem, // 240px
  63. 13: 18rem, // 288px
  64. 14: 20rem, // 320px
  65. 15: 25rem, // 400px
  66. 16: 30rem, // 480px
  67. 17: 35rem, // 560px
  68. 18: 40rem, // 640px
  69. 19: 45rem, // 720px
  70. 20: 50rem // 800px
  71. );
  72. // Typography
  73. // -------------------------
  74. $font-family-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  75. $font-family-heading: 'Poppins', sans-serif;
  76. // Font sizes
  77. $font-sizes: (
  78. 'xs': 0.75rem, // 12px
  79. 'sm': 0.875rem, // 14px
  80. 'base': 1rem, // 16px
  81. 'lg': 1.125rem, // 18px
  82. 'xl': 1.25rem, // 20px
  83. '2xl': 1.5rem, // 24px
  84. '3xl': 1.875rem, // 30px
  85. '4xl': 2.25rem, // 36px
  86. '5xl': 3rem, // 48px
  87. '6xl': 3.20rem
  88. );
  89. // Font weights
  90. $font-weights: (
  91. 'light': 300,
  92. 'regular': 400,
  93. 'medium': 500,
  94. 'semibold': 600,
  95. 'bold': 700
  96. );
  97. // Border radius
  98. // -------------------------
  99. $border-radius-sm: 0.25rem; // 4px
  100. $border-radius: 0.5rem; // 8px
  101. $border-radius-lg: 1rem; // 16px
  102. // Shadows
  103. // -------------------------
  104. $box-shadow: 0 0 20px rgba(116, 116, 116, 0.1);
  105. $box-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  106. $box-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  107. // Transitions
  108. // -------------------------
  109. $transition-base: all 0.3s ease-in-out;
  110. $transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  111. // Z-index
  112. // -------------------------
  113. $z-indices: (
  114. 'modal': 1000,
  115. 'dropdown': 900,
  116. 'navbar': 800,
  117. 'tooltip': 700,
  118. 'fixed': 500,
  119. 'above': 10,
  120. 'default': 1,
  121. 'below': -1
  122. );
  123. // Grid System Variables
  124. $grid-gap-base: 1.5rem !default;
  125. $grid-gap-sm: 1rem !default;
  126. $grid-gap-lg: 2rem !default;
  127. $grid-gap-xl: 3rem !default;
  128. // Grid Container Sizes (optional)
  129. $grid-container-sm: 540px !default;
  130. $grid-container-md: 720px !default;
  131. $grid-container-lg: 960px !default;
  132. $grid-container-xl: 1140px !default;
  133. $grid-container-xxl: 1320px !default;
  134. // Grid Breakpoints (should match your existing breakpoints)
  135. $grid-breakpoint-xs: 0 !default;
  136. $grid-breakpoint-sm: 576px !default;
  137. $grid-breakpoint-md: 768px !default;
  138. $grid-breakpoint-lg: 992px !default;
  139. $grid-breakpoint-xl: 1200px !default;
  140. $grid-breakpoint-xxl: 1400px !default;
  141. // ==========================================================================
  142. // THEME COLORS FOR LIGHT & DARK MODE
  143. // ==========================================================================
  144. // Define colors as CSS Custom Properties for dynamic theme switching.
  145. :root {
  146. // --- Light Mode Colors (Default Theme) ---
  147. --color-primary: #{$primary};
  148. --color-primary-light: #{$primary-light};
  149. --color-primary-dark: #{$primary-dark};
  150. --color-accent: #{$accent};
  151. --color-white: #{$white};
  152. --color-black: #{$black};
  153. // Backgrounds and Surfaces
  154. --color-background: #{$primary-dark}; // Main background color for <body>
  155. --color-surface: #{$white}; // Background for "boxes" like cards and sections
  156. --color-surface-scase: #f8f9fa; // Background for article.html
  157. --color-border: #{$light-gray}; // Color for borders and separators
  158. // Text Colors in Light Mode
  159. --color-text-primary: #{$black}; // For Headers (h1, h2, h3...) and very important text
  160. --color-text-secondary: #{$dark-gray}; // For paragraphs (p) and main body text
  161. --color-text-muted: #{$black}; // For less important text (metadata, placeholders, etc.)
  162. --color-surface-mcase: #{$black}; // Text color for article.html
  163. // Shadows
  164. --box-shadow: #{$box-shadow};
  165. --box-shadow-sm: #{$box-shadow-sm};
  166. --box-shadow-lg: #{$box-shadow-lg};
  167. --box-shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.15);
  168. // Menu Color
  169. --menu-icon-color: #{$black};
  170. }
  171. // --- Dark Mode Styles ---
  172. body.dark-mode {
  173. --color-background: #{$black};
  174. --color-surface: #{$black};
  175. --color-surface-scase: #{$black};
  176. --color-border: #30363d;
  177. --color-white: #{$black};
  178. --color-black: #{$white};
  179. --color-text-primary: rgba(255, 255, 255, 0.87);
  180. --color-text-secondary: rgba(255, 255, 255, 0.60);
  181. --color-text-muted: var(--color-text-secondary);
  182. --color-surface-mcase: #{$white};
  183. --box-shadow: 0 0 20px #{rgba($primary, 0.2)};
  184. --box-shadow-sm: 0 1px 2px #{rgba($primary, 0.15)};
  185. --box-shadow-lg: 0 10px 15px -3px #{rgba($primary, 0.2)};
  186. --box-shadow-hover: var(--box-shadow);
  187. --menu-icon-color: #{$white};
  188. }