ShopUI.uss 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432
  1. /* Shop UI Styles - Unity Compatible Version */
  2. #ShopContainer {
  3. position: absolute;
  4. width: 100%;
  5. height: 100%;
  6. background-color: rgba(0, 0, 0, 0.8);
  7. justify-content: center;
  8. align-items: center;
  9. display: none; /* Hidden by default, script will show it */
  10. }
  11. #ShopWindow {
  12. width: 650px;
  13. height: 550px;
  14. min-width: 450px;
  15. min-height: 350px;
  16. max-width: 800px;
  17. max-height: 650px;
  18. background-color: rgb(240, 240, 240);
  19. border-top-left-radius: 10px;
  20. border-top-right-radius: 10px;
  21. border-bottom-left-radius: 10px;
  22. border-bottom-right-radius: 10px;
  23. border-left-width: 2px;
  24. border-right-width: 2px;
  25. border-top-width: 2px;
  26. border-bottom-width: 2px;
  27. border-left-color: rgb(100, 100, 100);
  28. border-right-color: rgb(100, 100, 100);
  29. border-top-color: rgb(100, 100, 100);
  30. border-bottom-color: rgb(100, 100, 100);
  31. padding-left: 20px;
  32. padding-right: 20px;
  33. padding-top: 20px;
  34. padding-bottom: 20px;
  35. }
  36. #ShopTitle {
  37. font-size: 24px;
  38. color: rgb(50, 50, 50);
  39. -unity-font-style: bold;
  40. }
  41. #PlayerMoney {
  42. color: rgb(0, 120, 0);
  43. font-size: 16px;
  44. -unity-font-style: bold;
  45. }
  46. #CloseButton {
  47. width: 30px;
  48. height: 30px;
  49. background-color: rgb(200, 50, 50);
  50. color: white;
  51. border-top-left-radius: 15px;
  52. border-top-right-radius: 15px;
  53. border-bottom-left-radius: 15px;
  54. border-bottom-right-radius: 15px;
  55. border-left-width: 0;
  56. border-right-width: 0;
  57. border-top-width: 0;
  58. border-bottom-width: 0;
  59. font-size: 16px;
  60. -unity-font-style: bold;
  61. }
  62. #CloseButton:hover {
  63. background-color: rgb(220, 70, 70);
  64. }
  65. /* Shop Controls container */
  66. #ShopControls {
  67. flex-direction: column;
  68. flex-shrink: 0; /* Prevent shrinking */
  69. width: 100%; /* Take full width of parent */
  70. max-width: 610px; /* Ensure it fits within ShopWindow (650px - 40px padding) */
  71. }
  72. /* Search row container */
  73. #SearchRow {
  74. flex-direction: row;
  75. align-items: center;
  76. width: 100%;
  77. margin-bottom: 10px;
  78. }
  79. /* Category row container */
  80. #CategoryRow {
  81. flex-direction: row;
  82. align-items: center;
  83. width: 100%;
  84. }
  85. #SearchField {
  86. flex-grow: 1;
  87. margin-right: 0px;
  88. max-width: none; /* Allow it to take full width */
  89. min-width: 200px; /* Ensure minimum usability */
  90. color: rgb(50, 50, 50); /* Text color for visibility */
  91. background-color: transparent; /* Transparent background to match window */
  92. }
  93. /* Style the search field's text input specifically */
  94. #SearchField .unity-text-field__input {
  95. color: rgb(50, 50, 50);
  96. background-color: white;
  97. border-left-width: 1px;
  98. border-right-width: 1px;
  99. border-top-width: 1px;
  100. border-bottom-width: 1px;
  101. border-left-color: rgb(180, 180, 180);
  102. border-right-color: rgb(180, 180, 180);
  103. border-top-color: rgb(180, 180, 180);
  104. border-bottom-color: rgb(180, 180, 180);
  105. border-top-left-radius: 3px;
  106. border-top-right-radius: 3px;
  107. border-bottom-left-radius: 3px;
  108. border-bottom-right-radius: 3px;
  109. padding-left: 5px;
  110. padding-right: 5px;
  111. padding-top: 3px;
  112. padding-bottom: 3px;
  113. }
  114. /* Focus state for search field */
  115. #SearchField .unity-text-field__input:focus {
  116. border-left-color: rgb(100, 150, 255);
  117. border-right-color: rgb(100, 150, 255);
  118. border-top-color: rgb(100, 150, 255);
  119. border-bottom-color: rgb(100, 150, 255);
  120. border-left-width: 2px;
  121. border-right-width: 2px;
  122. border-top-width: 2px;
  123. border-bottom-width: 2px;
  124. }
  125. /* Style the search field label */
  126. #SearchField .unity-text-field__label {
  127. color: rgb(50, 50, 50);
  128. background-color: transparent; /* Remove white background */
  129. font-size: 12px;
  130. margin-right: 5px;
  131. min-width: 50px;
  132. }
  133. /* Style the category filter */
  134. #CategoryFilter .unity-dropdown-field__input {
  135. color: rgb(50, 50, 50);
  136. background-color: white;
  137. border-left-width: 1px;
  138. border-right-width: 1px;
  139. border-top-width: 1px;
  140. border-bottom-width: 1px;
  141. border-left-color: rgb(180, 180, 180);
  142. border-right-color: rgb(180, 180, 180);
  143. border-top-color: rgb(180, 180, 180);
  144. border-bottom-color: rgb(180, 180, 180);
  145. border-top-left-radius: 3px;
  146. border-top-right-radius: 3px;
  147. border-bottom-left-radius: 3px;
  148. border-bottom-right-radius: 3px;
  149. padding-left: 8px; /* Increased padding for better text spacing */
  150. padding-right: 25px; /* More space for dropdown arrow */
  151. padding-top: 4px;
  152. padding-bottom: 4px;
  153. min-height: 20px; /* Ensure minimum height for text visibility */
  154. }
  155. /* Style the dropdown arrow/button area */
  156. #CategoryFilter .unity-dropdown-field__arrow {
  157. color: rgb(100, 100, 100);
  158. background-color: transparent;
  159. }
  160. /* Style the text display in closed state */
  161. #CategoryFilter .unity-dropdown-field__text {
  162. color: rgb(50, 50, 50);
  163. font-size: 12px;
  164. padding-left: 2px;
  165. padding-right: 2px;
  166. }
  167. /* Style the category filter label */
  168. #CategoryFilter .unity-dropdown-field__label {
  169. color: rgb(50, 50, 50);
  170. background-color: transparent; /* Remove white background */
  171. font-size: 12px;
  172. margin-right: 8px; /* Increased margin for better spacing */
  173. min-width: 70px; /* Slightly increased width */
  174. }
  175. /* Hide scrollbars in the dropdown */
  176. #CategoryFilter .unity-scroll-view__horizontal-scroller {
  177. display: none !important;
  178. }
  179. #CategoryFilter .unity-scroll-view__vertical-scroller {
  180. display: none !important;
  181. }
  182. /* Additional scrollbar hiding for dropdown popup */
  183. #CategoryFilter .unity-scroll-view {
  184. overflow: hidden;
  185. }
  186. #CategoryFilter .unity-scroll-view__content-viewport {
  187. overflow: hidden;
  188. }
  189. /* Hide any scrollbars in the dropdown list */
  190. #CategoryFilter .unity-dropdown-field__list {
  191. overflow: hidden;
  192. }
  193. #CategoryFilter .unity-dropdown-field__list .unity-scroll-view__horizontal-scroller {
  194. display: none !important;
  195. }
  196. #CategoryFilter .unity-dropdown-field__list .unity-scroll-view__vertical-scroller {
  197. display: none !important;
  198. }
  199. /* Hide scrollbars for any popup content */
  200. #CategoryFilter .unity-base-popup-field__popup .unity-scroll-view__horizontal-scroller {
  201. display: none !important;
  202. }
  203. #CategoryFilter .unity-base-popup-field__popup .unity-scroll-view__vertical-scroller {
  204. display: none !important;
  205. }
  206. /* Target the popup window specifically */
  207. #CategoryFilter .unity-base-popup-field__popup {
  208. overflow: hidden;
  209. }
  210. #CategoryFilter .unity-base-popup-field__popup .unity-scroll-view {
  211. overflow: hidden;
  212. }
  213. /* Hide horizontal scrollers in popup content */
  214. #CategoryFilter .unity-popup__content-container .unity-scroll-view__horizontal-scroller {
  215. display: none !important;
  216. }
  217. /* Force all dropdown list items to fit within container */
  218. #CategoryFilter .unity-dropdown-field__list .unity-label {
  219. white-space: nowrap;
  220. overflow: hidden;
  221. text-overflow: ellipsis;
  222. max-width: 280px;
  223. }
  224. /* Style the dropdown popup/menu */
  225. #CategoryFilter .unity-base-popup-field__arrow {
  226. color: rgb(100, 100, 100);
  227. }
  228. /* Ensure dropdown content fits properly */
  229. #CategoryFilter .unity-dropdown-field__container {
  230. overflow: hidden;
  231. }
  232. #CategoryFilter {
  233. width: 400px; /* Increased from 300px to give more space for text */
  234. flex-shrink: 0; /* Prevent it from shrinking */
  235. background-color: transparent; /* Match window background */
  236. overflow: hidden; /* Hide any overflow content */
  237. }
  238. /* Global scrollbar hiding for all elements within CategoryFilter */
  239. #CategoryFilter * {
  240. overflow: hidden;
  241. }
  242. /* Force hide all scrollbars globally within the category filter */
  243. #CategoryFilter .unity-scroller {
  244. display: none !important;
  245. }
  246. #CategoryFilter .unity-scroller__slider {
  247. display: none !important;
  248. }
  249. #CategoryFilter .unity-scroller__low-button {
  250. display: none !important;
  251. }
  252. #CategoryFilter .unity-scroller__high-button {
  253. display: none !important;
  254. }
  255. /* Target Unity's internal scrollbar elements */
  256. #CategoryFilter .unity-scroller--horizontal {
  257. display: none !important;
  258. }
  259. #CategoryFilter .unity-scroller--vertical {
  260. display: none !important;
  261. }
  262. /* Hide all scrollbar track elements */
  263. #CategoryFilter .unity-scroller__track {
  264. display: none !important;
  265. }
  266. /* Hide scrollbar dragger elements */
  267. #CategoryFilter .unity-scroller__dragger {
  268. display: none !important;
  269. }
  270. /* Hide repeat buttons */
  271. #CategoryFilter .unity-repeat-button {
  272. display: none !important;
  273. }
  274. /* Global nuclear option - hide ALL scrollers */
  275. #CategoryFilter .unity-base-field__input .unity-scroller {
  276. display: none !important;
  277. }
  278. #CategoryFilter .unity-popup-field__input .unity-scroller {
  279. display: none !important;
  280. }
  281. /* Target any element with "scroller" in the class name */
  282. #CategoryFilter [class*="scroller"] {
  283. display: none !important;
  284. }
  285. /* Target any element with "scroll" in the class name */
  286. #CategoryFilter [class*="scroll"] {
  287. display: none !important;
  288. }
  289. #ItemList {
  290. background-color: white;
  291. border-left-width: 1px;
  292. border-right-width: 1px;
  293. border-top-width: 1px;
  294. border-bottom-width: 1px;
  295. border-left-color: rgb(180, 180, 180);
  296. border-right-color: rgb(180, 180, 180);
  297. border-top-color: rgb(180, 180, 180);
  298. border-bottom-color: rgb(180, 180, 180);
  299. border-top-left-radius: 5px;
  300. border-top-right-radius: 5px;
  301. border-bottom-left-radius: 5px;
  302. border-bottom-right-radius: 5px;
  303. padding-left: 10px;
  304. padding-right: 10px;
  305. padding-top: 10px;
  306. padding-bottom: 10px;
  307. flex-grow: 1;
  308. min-height: 200px;
  309. }
  310. .shop-item {
  311. background-color: rgb(248, 248, 248);
  312. border-top-left-radius: 5px;
  313. border-top-right-radius: 5px;
  314. border-bottom-left-radius: 5px;
  315. border-bottom-right-radius: 5px;
  316. padding-left: 10px;
  317. padding-right: 10px;
  318. padding-top: 10px;
  319. padding-bottom: 10px;
  320. margin-bottom: 5px;
  321. flex-direction: row;
  322. justify-content: space-between;
  323. align-items: center;
  324. }
  325. .shop-item:hover {
  326. background-color: rgb(235, 235, 235);
  327. }
  328. .item-name {
  329. font-size: 16px;
  330. color: rgb(50, 50, 50);
  331. -unity-font-style: bold;
  332. }
  333. .item-description {
  334. font-size: 12px;
  335. color: rgb(100, 100, 100);
  336. margin-top: 2px;
  337. }
  338. .item-stats {
  339. font-size: 11px;
  340. color: rgb(80, 80, 150);
  341. margin-top: 2px;
  342. }
  343. .item-price {
  344. font-size: 14px;
  345. color: rgb(0, 120, 0);
  346. -unity-font-style: bold;
  347. margin-right: 10px;
  348. }
  349. .buy-button {
  350. width: 80px;
  351. height: 25px;
  352. background-color: rgb(50, 150, 50);
  353. color: white;
  354. border-top-left-radius: 3px;
  355. border-top-right-radius: 3px;
  356. border-bottom-left-radius: 3px;
  357. border-bottom-right-radius: 3px;
  358. border-left-width: 0;
  359. border-right-width: 0;
  360. border-top-width: 0;
  361. border-bottom-width: 0;
  362. font-size: 12px;
  363. }
  364. .buy-button:hover {
  365. background-color: rgb(70, 170, 70);
  366. }
  367. .buy-button:disabled {
  368. background-color: rgb(150, 150, 150);
  369. color: rgb(200, 200, 200);
  370. }
  371. .cannot-afford {
  372. background-color: rgb(150, 150, 150);
  373. color: rgb(200, 200, 200);
  374. }