styles.scss 8.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294
  1. /***********************************************************
  2. ############################################################
  3. . . . . . .
  4. . . ...-..-| |-. .-. .-.-..-| .-.. ...-|
  5. ` ` '' '`-'-' '-`-`-' ' '`-'-`-`-` '`-'-
  6. url - https://davidawindham.com
  7. git - https://github.com/windhamdavid/daw
  8. need to test
  9. ############################################################
  10. ************************************************************/
  11. /***********************************************************
  12. ################### Bootstrap Functions ####################
  13. ************************************************************/
  14. @import '../node_modules/bootstrap/scss/functions';
  15. @import '../node_modules/bootstrap/scss/variables';
  16. @import '../node_modules/bootstrap/scss/variables-dark';
  17. @import '../node_modules/bootstrap/scss/maps';
  18. @import '../node_modules/bootstrap/scss/mixins';
  19. /***********************************************************
  20. ####################### Custom ############################
  21. ************************************************************/
  22. $body-bg: #d3d3d3;
  23. $body-color: #232323;
  24. $link-color: #67000a;
  25. $theme-colors: (
  26. "dark": #535763,
  27. );
  28. $custom-colors: (
  29. 'dw-blue-dark': #484C57,
  30. 'dw-blue':#535763,
  31. 'dw-light':#e2e2e2,
  32. 'dw-bright':#e3e3e3,
  33. );
  34. $theme-colors: map-merge($theme-colors, $custom-colors);
  35. $theme-colors: map-remove($theme-colors, 'primary','secondary','success','warning', 'info');
  36. $colors: map-remove($colors, 'white','black','gray','gray-dark','dark','blue','indigo','purple','pink', 'orange', 'yellow', 'green', 'teal', 'cyan');
  37. $theme-colors-rgb: map-loop($theme-colors, to-rgb, "$value");
  38. $utilities-colors: map-merge($utilities-colors, $theme-colors-rgb);
  39. $utilities-text-colors: map-loop($utilities-colors, rgba-css-var, "$key", "text");
  40. $utilities-bg-colors: map-loop($utilities-colors, rgba-css-var, "$key", "bg");
  41. $enable-negative-margins: true;
  42. /***********************************************************
  43. ########## Bootstrap 5 — subset to used parts #############
  44. Being removed incrementally (Phase 1, 2026-07-13).
  45. Dropped (unused / migrated): dropdown, button-group, accordion,
  46. breadcrumb, progress, toasts, modal, tooltip, popover, spinners,
  47. placeholders, carousel (→ native .dw-carousel), tables, close,
  48. images (→ .img-fluid one-liner below).
  49. Kept: grid + nav/navbar + forms/buttons + list-group + card +
  50. pagination + alert + badge (last.fm stat counts) + utilities API.
  51. (offcanvas nav is self-contained CSS via :target — see .dw-offcanvas.)
  52. ************************************************************/
  53. @import '../node_modules/bootstrap/scss/utilities';
  54. @import '../node_modules/bootstrap/scss/root';
  55. @import '../node_modules/bootstrap/scss/reboot';
  56. @import '../node_modules/bootstrap/scss/type';
  57. @import '../node_modules/bootstrap/scss/containers';
  58. @import '../node_modules/bootstrap/scss/grid';
  59. @import '../node_modules/bootstrap/scss/forms';
  60. @import '../node_modules/bootstrap/scss/buttons';
  61. @import '../node_modules/bootstrap/scss/transitions';
  62. @import '../node_modules/bootstrap/scss/nav';
  63. @import '../node_modules/bootstrap/scss/navbar';
  64. @import '../node_modules/bootstrap/scss/card';
  65. @import '../node_modules/bootstrap/scss/pagination';
  66. @import '../node_modules/bootstrap/scss/alert';
  67. @import '../node_modules/bootstrap/scss/list-group';
  68. @import '../node_modules/bootstrap/scss/badge';
  69. @import '../node_modules/bootstrap/scss/helpers';
  70. @import '../node_modules/bootstrap/scss/utilities/api';
  71. // Replaces the dropped bootstrap/images partial (only .img-fluid was used).
  72. .img-fluid {
  73. max-width: 100%;
  74. height: auto;
  75. }
  76. /* Bootstrap Icons font dropped (2026-06-19): the header's 8 nav icons are now
  77. inline SVG in parts/header.html, so the full icon font + its ~2000 CSS rules
  78. are no longer imported. */
  79. /***********************************************************
  80. ##################### Overrides ############################
  81. ************************************************************/
  82. // Bootstrap 5.3 changed .table to default --bs-table-bg to --bs-body-bg
  83. // (it was transparent in 5.2). Keep the About icon grid transparent.
  84. .table.icons {
  85. --bs-table-bg: transparent;
  86. }
  87. // Sprite icons (dw_icon() / <use href="#dw-…">, from the FA Pro kit → icons.svg).
  88. // Sized like a font icon: 1em square, inherits text color.
  89. .dw-icon {
  90. width: 1em;
  91. height: 1em;
  92. fill: currentColor;
  93. vertical-align: -0.125em;
  94. }
  95. // Social icons (was fa-2x). Baseline-aligned since they stand alone.
  96. .dw-icon-2x {
  97. width: 2em;
  98. height: 2em;
  99. vertical-align: middle;
  100. }
  101. // Offcanvas top-nav — self-contained, CSS-only (replaces Bootstrap's offcanvas
  102. // component + JS). The brand link is <a href="#nav">, so :target drives
  103. // the open state; a backdrop <a href="#"> and the × link close it. Tradeoffs vs
  104. // the BS JS version: no ESC-to-close, no focus-trap, no body-scroll-lock.
  105. .dw-offcanvas {
  106. position: fixed;
  107. top: 0;
  108. left: 0;
  109. right: 0;
  110. z-index: 1045; // above .navbar.fixed-top (1030)
  111. display: flex;
  112. flex-direction: column;
  113. height: 85px; // match the scroll-up navbar dropdown (~84.6px)
  114. visibility: hidden;
  115. transform: translateY(-100%);
  116. transition: transform 0.3s ease-in-out, visibility 0.3s;
  117. overflow-y: auto;
  118. background: rgba(72, 76, 87, 0.7); // footer color (#484c57), translucent
  119. backdrop-filter: blur(6px);
  120. }
  121. .dw-offcanvas:target {
  122. visibility: visible;
  123. transform: none;
  124. }
  125. .dw-offcanvas-backdrop {
  126. display: none;
  127. position: fixed;
  128. inset: 0;
  129. z-index: 1040; // below .dw-offcanvas
  130. background: rgba(0, 0, 0, 0.4);
  131. }
  132. .dw-offcanvas:target ~ .dw-offcanvas-backdrop {
  133. display: block;
  134. }
  135. @media (prefers-reduced-motion: reduce) {
  136. .dw-offcanvas {
  137. transition: none;
  138. }
  139. }
  140. // Gallery carousel — CSS scroll-snap (replaces the Bootstrap carousel on the
  141. // art page). Swipe / trackpad / scrollbar natively; prev-next + arrow keys via
  142. // a tiny vanilla script (js/art.js). No autoplay (was 5s) by design.
  143. .dw-carousel {
  144. position: relative;
  145. }
  146. .dw-carousel-track {
  147. display: flex;
  148. overflow-x: auto;
  149. scroll-snap-type: x mandatory;
  150. scroll-behavior: smooth;
  151. scrollbar-width: none; // Firefox
  152. &::-webkit-scrollbar {
  153. display: none; // WebKit
  154. }
  155. }
  156. .dw-carousel-slide {
  157. flex: 0 0 100%;
  158. scroll-snap-align: center;
  159. display: flex;
  160. justify-content: center;
  161. }
  162. .dw-carousel-prev,
  163. .dw-carousel-next {
  164. position: absolute;
  165. top: 50%;
  166. transform: translateY(-50%);
  167. z-index: 2;
  168. width: 3rem;
  169. height: 3rem;
  170. border: 0;
  171. border-radius: 50%;
  172. background: rgba(0, 0, 0, 0.5);
  173. color: #fff;
  174. font-size: 1.75rem;
  175. line-height: 1;
  176. cursor: pointer;
  177. }
  178. .dw-carousel-prev {
  179. left: 1rem;
  180. }
  181. .dw-carousel-next {
  182. right: 1rem;
  183. }
  184. @media (prefers-reduced-motion: reduce) {
  185. .dw-carousel-track {
  186. scroll-behavior: auto;
  187. }
  188. }
  189. // Studio hero — vanilla fade-carousel (replaces Bootstrap carousel-fade + the
  190. // backstretch background). #studio-caro keeps its caro-grad* solid-colour
  191. // classes + 1s transition from style.css; the bg layer / <video> show through
  192. // when the gradient is caro-grad5 (transparent). Driven by js/studio.js.
  193. #studio-caro {
  194. position: relative;
  195. overflow: hidden;
  196. min-height: 80vh;
  197. }
  198. .dw-studio-bg {
  199. position: absolute;
  200. inset: 0;
  201. z-index: 0;
  202. background-size: cover;
  203. background-position: center;
  204. }
  205. .dw-studio-video,
  206. .dw-studio-tv {
  207. position: absolute;
  208. inset: 0;
  209. width: 100%;
  210. height: 100%;
  211. object-fit: cover;
  212. display: none; // shown per-slide by studio.js (camera → Media, tv → fact intro)
  213. }
  214. .dw-studio-tv {
  215. filter: saturate(0); // grayscale, as it was behind the About fact slides
  216. }
  217. .dw-fade-carousel {
  218. position: relative;
  219. z-index: 1;
  220. }
  221. .dw-fade-slide {
  222. position: absolute;
  223. inset: 0;
  224. opacity: 0;
  225. visibility: hidden;
  226. transition: opacity 0.8s ease;
  227. }
  228. .dw-fade-slide.active {
  229. position: relative; // the active slide defines the track height
  230. opacity: 1;
  231. visibility: visible;
  232. }
  233. @media (prefers-reduced-motion: reduce) {
  234. .dw-fade-slide {
  235. transition: none;
  236. }
  237. }
  238. // Studio tab panes — vanilla show/hide (replaces Bootstrap Tab).
  239. #studio-tab .tab-pane {
  240. display: none;
  241. }
  242. #studio-tab .tab-pane.active {
  243. display: block;
  244. }
  245. // About fade-carousel indicator dots (replaces Bootstrap .carousel-indicators).
  246. .dw-fade-dots {
  247. position: absolute;
  248. bottom: 1.5rem;
  249. left: 0;
  250. right: 0;
  251. z-index: 3;
  252. display: flex;
  253. justify-content: center;
  254. gap: 0.5rem;
  255. }
  256. .dw-fade-dot {
  257. width: 12px;
  258. height: 12px;
  259. padding: 0;
  260. border: 1px solid #fff;
  261. border-radius: 50%;
  262. background: transparent;
  263. opacity: 0.6;
  264. cursor: pointer;
  265. }
  266. .dw-fade-dot.active {
  267. background: #fff;
  268. opacity: 1;
  269. }