global.css 9.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471
  1. /* =============================================================================
  2. DIWO Vergleich - Global CSS
  3. =============================================================================
  4. Gemeinsame Stile die von allen Seiten verwendet werden:
  5. - CSS Custom Properties (Variablen)
  6. - Reset & Base Styles
  7. - Layout Components
  8. - Form Elements
  9. - Button Styles
  10. - Table Styles
  11. - Section Components (Collapsible Sections)
  12. ============================================================================= */
  13. /* =============================================================================
  14. CSS CUSTOM PROPERTIES (VARIABLEN)
  15. ============================================================================= */
  16. :root {
  17. /* Standard Farben mit verbessertem Kontrast */
  18. --rot-hell: #ffe6e6;
  19. --gelb-hell: #fff8db;
  20. --gruen-hell: #e8f5e8;
  21. --rot: #b30000;
  22. --gelb: #9d5502;
  23. --gruen: #004d26;
  24. --weiss: #ffffff;
  25. --schwarz: #000000;
  26. --grau-hell: #f7f9fa;
  27. --grau-stark: #d7d8d9;
  28. --diwo-blau: #145c9e;
  29. --diwo-blau-hell: #cfe8fc;
  30. /* Focus Ring Farbe für bessere Sichtbarkeit */
  31. --focus-color: #0066cc;
  32. --focus-outline: 3px solid var(--focus-color);
  33. }
  34. /* Alternative Farben mit besserem Kontrast */
  35. :root[data-color-scheme="alt-a"] {
  36. --rot-hell: #ffe6f5;
  37. --gelb-hell: #fff2cc;
  38. --gruen-hell: #e6f7ff;
  39. --rot: #cc0044;
  40. --gelb: #b8620e;
  41. --gruen: #0077b6;
  42. }
  43. /* Alternative B – maximale Kontrastunterscheidung */
  44. :root[data-color-scheme="alt-b"] {
  45. --rot-hell: #ffe6f0;
  46. --gelb-hell: #e6ebff;
  47. --gruen-hell: #eaf7d4;
  48. --rot: #d00070;
  49. --gelb:#0040ff ;
  50. --gruen: #7a9e00;
  51. }
  52. /* Alternative Pastell (ohne Ampel-Assoziation) */
  53. :root[data-color-scheme="alt-pastell"] {
  54. --rot-hell:#ffeef2 ;
  55. --gelb-hell:#f3e8ff;
  56. --gruen-hell: #e8f0ff;
  57. --rot: #e67891;
  58. --gelb: #9d6ee8;
  59. --gruen: #4f9df7;
  60. }
  61. /* =============================================================================
  62. RESET & BASE STYLES
  63. ============================================================================= */
  64. * {
  65. box-sizing: border-box;
  66. }
  67. body {
  68. margin: 0;
  69. padding: 16px;
  70. background: var(--grau-hell);
  71. color: var(--schwarz);
  72. font: 14px/1.5 system-ui, sans-serif;
  73. }
  74. h1, h2, h3 {
  75. margin: 0.2rem 0 0.6rem;
  76. line-height: 1.3;
  77. }
  78. /* Focus-Stile für bessere Keyboard-Navigation */
  79. *:focus {
  80. outline: var(--focus-outline);
  81. outline-offset: 2px;
  82. }
  83. button:focus,
  84. select:focus,
  85. input:focus,
  86. .person-row:focus,
  87. .section-header:focus {
  88. outline: var(--focus-outline);
  89. outline-offset: 2px;
  90. }
  91. tr:focus {
  92. outline: var(--focus-outline);
  93. outline-offset: 1px;
  94. position: relative;
  95. z-index: 1;
  96. }
  97. /* =============================================================================
  98. LAYOUT COMPONENTS
  99. ============================================================================= */
  100. .row {
  101. display: flex;
  102. gap: 0.5rem;
  103. align-items: center;
  104. }
  105. .grid-2 {
  106. display: grid;
  107. grid-template-columns: 1fr 1fr;
  108. gap: 12px;
  109. }
  110. .grid-2 .full {
  111. grid-column: 1/-1;
  112. }
  113. .error-box {
  114. background: var(--rot-hell);
  115. border-left: 4px solid var(--rot);
  116. padding: 0.6rem;
  117. margin: 0.6rem 0;
  118. border-radius: 4px;
  119. }
  120. /* =============================================================================
  121. FORM ELEMENTS
  122. ============================================================================= */
  123. textarea,
  124. input,
  125. select {
  126. width: 100%;
  127. padding: 0.5rem;
  128. background: var(--weiss);
  129. color: var(--schwarz);
  130. border: 2px solid var(--grau-stark);
  131. border-radius: 4px;
  132. font-size: 14px;
  133. }
  134. textarea:hover,
  135. input:hover,
  136. select:hover {
  137. border-color: var(--diwo-blau);
  138. }
  139. .control-group {
  140. display: flex;
  141. align-items: center;
  142. gap: 8px;
  143. }
  144. .control-group label {
  145. font-size: 13px;
  146. font-weight: bold;
  147. white-space: nowrap;
  148. }
  149. /* =============================================================================
  150. BUTTON STYLES
  151. ============================================================================= */
  152. button {
  153. padding: 0.5rem 0.9rem;
  154. border: 2px solid var(--grau-stark);
  155. background: var(--weiss);
  156. cursor: pointer;
  157. font-size: 14px;
  158. min-height: 44px;
  159. transition: all 0.2s ease;
  160. }
  161. button:hover {
  162. background: var(--grau-hell);
  163. border-color: var(--diwo-blau);
  164. }
  165. button:active {
  166. transform: translateY(1px);
  167. }
  168. /* =============================================================================
  169. TABLE STYLES
  170. ============================================================================= */
  171. table {
  172. width: 100%;
  173. border-collapse: collapse;
  174. background: var(--weiss);
  175. border: 1px solid var(--grau-stark);
  176. margin: 0.6rem 0 1rem;
  177. border-spacing: 0;
  178. }
  179. th, td {
  180. border: 1px solid var(--grau-stark);
  181. padding: 0.5rem;
  182. vertical-align: top;
  183. text-align: left;
  184. }
  185. th {
  186. background: var(--grau-stark);
  187. position: sticky;
  188. top: 0;
  189. font-weight: bold;
  190. color: var(--schwarz);
  191. }
  192. /* Symbol-Spalte */
  193. .sym {
  194. width: 2.5rem;
  195. min-width: 2.5rem;
  196. max-width: 2.5rem;
  197. text-align: center;
  198. font-weight: 700;
  199. font-size: 16px;
  200. }
  201. .sym.plus {
  202. color: var(--gruen);
  203. }
  204. .sym.minus {
  205. color: var(--rot);
  206. }
  207. .sym.warn {
  208. color: var(--gelb);
  209. }
  210. /* FontAwesome Icons in Symbol-Spalte */
  211. .sym i.fas {
  212. font-family: "Font Awesome 6 Free";
  213. font-weight: 900;
  214. font-style: normal;
  215. font-variant: normal;
  216. text-rendering: auto;
  217. line-height: 1;
  218. }
  219. .sym i.fa-plus,
  220. .sym i.fa-minus,
  221. .sym i.fa-exclamation {
  222. font-size: 16px;
  223. display: inline-block;
  224. }
  225. /* Diff-Highlighting für Tabellenzeilen */
  226. .diff-row-added {
  227. background: var(--gruen-hell);
  228. }
  229. .diff-row-removed {
  230. background: var(--rot-hell);
  231. }
  232. /* =============================================================================
  233. NEUE ICON-BASIERTE DIFF-DARSTELLUNG
  234. ============================================================================= */
  235. /* Container für den neuen Icon+Text Layout */
  236. .diff-content {
  237. display: flex;
  238. align-items: flex-start;
  239. min-height: 2.4em;
  240. gap: 2px;
  241. }
  242. .diff-icon {
  243. flex-shrink: 0;
  244. width: 18px; /* Größeres Icon */
  245. height: 18px; /* Größeres Icon */
  246. font-size: 16px; /* Größere Schrift für das Icon */
  247. display: flex;
  248. align-items: center;
  249. justify-content: center;
  250. margin-top: 0.1em; /* Kleinerer Abstand oben */
  251. position: relative;
  252. }
  253. .diff-text {
  254. flex: 1;
  255. line-height: 1.3;
  256. min-width: 0; /* Verhindert Overflow-Probleme */
  257. }
  258. .diff-current-value {
  259. display: block;
  260. font-weight: normal;
  261. word-wrap: break-word;
  262. overflow-wrap: break-word;
  263. }
  264. .diff-status-text {
  265. display: block;
  266. font-size: 0.85em;
  267. margin-top: 0.3rem;
  268. opacity: 0.9;
  269. font-style: italic;
  270. word-wrap: break-word;
  271. overflow-wrap: break-word;
  272. }
  273. /* Icon-spezifische Farben mit besserer Sichtbarkeit */
  274. .diff-icon.changed {
  275. color: var(--gelb);
  276. }
  277. .diff-icon.added {
  278. color: var(--gruen);
  279. }
  280. .diff-icon.deleted {
  281. color: var(--rot);
  282. }
  283. /* FontAwesome Icons in Diff-Icons */
  284. .diff-icon i.fas {
  285. font-family: "Font Awesome 6 Free";
  286. font-weight: 900;
  287. font-style: normal;
  288. font-variant: normal;
  289. text-rendering: auto;
  290. line-height: 1;
  291. }
  292. /* Hintergrundfarben für die Zellen */
  293. .cell-changed,
  294. td:has(.cell-changed) {
  295. background: var(--gelb-hell);
  296. }
  297. .cell-added,
  298. td:has(.cell-added) {
  299. background: var(--gruen-hell);
  300. }
  301. .cell-deleted,
  302. td:has(.cell-deleted) {
  303. background: var(--rot-hell);
  304. }
  305. /* =============================================================================
  306. KOPIER-BUTTONS FÜR ALTE WERTE
  307. ============================================================================= */
  308. .copy-btn {
  309. display: inline;
  310. margin-left: 0.25rem;
  311. padding: 0;
  312. font-size: 10px;
  313. line-height: 1;
  314. background: transparent;
  315. border: none;
  316. cursor: pointer;
  317. color: var(--schwarz);
  318. transition: all 0.15s ease;
  319. vertical-align: baseline;
  320. opacity: 0.6;
  321. height: auto;
  322. width: auto;
  323. min-height: unset !important;
  324. }
  325. .copy-btn i {
  326. font-size: 10px;
  327. line-height: 1;
  328. vertical-align: baseline;
  329. }
  330. .copy-btn:hover {
  331. opacity: 1;
  332. transform: scale(1.1);
  333. color: var(--schwarz);
  334. }
  335. .copy-btn:focus {
  336. outline: 1px solid var(--focus-color);
  337. outline-offset: 1px;
  338. opacity: 1;
  339. }
  340. .copy-btn:active {
  341. transform: scale(0.95);
  342. }
  343. /* Feedback-Stile für Kopier-Buttons */
  344. .copy-btn.copy-success {
  345. color: var(--gruen);
  346. opacity: 1;
  347. }
  348. .copy-btn.copy-error {
  349. color: var(--rot);
  350. opacity: 1;
  351. }
  352. /* Kopier-Buttons im neuen Diff-Layout */
  353. .diff-status-text .copy-btn {
  354. font-style: normal;
  355. }
  356. /* =============================================================================
  357. SECTION COMPONENTS (COLLAPSIBLE SECTIONS)
  358. ============================================================================= */
  359. .section-container {
  360. margin: 0.6rem 0 1rem;
  361. }
  362. .section-header {
  363. background: var(--grau-stark);
  364. padding: 12px 16px;
  365. border: 2px solid var(--grau-stark);
  366. border-radius: 4px 4px 0 0;
  367. cursor: pointer;
  368. display: flex;
  369. align-items: center;
  370. gap: 8px;
  371. user-select: none;
  372. transition: all 0.2s ease;
  373. min-height: 44px;
  374. }
  375. .section-header:hover {
  376. background: #c5c6c7;
  377. border-color: var(--diwo-blau);
  378. }
  379. .section-header h3 {
  380. margin: 0;
  381. font-size: 16px;
  382. font-weight: bold;
  383. }
  384. .toggle-icon {
  385. font-size: 14px;
  386. transition: transform 0.2s ease;
  387. font-weight: bold;
  388. }
  389. .toggle-icon.collapsed {
  390. transform: rotate(-90deg);
  391. }
  392. .section-content {
  393. border: 2px solid var(--grau-stark);
  394. border-top: none;
  395. border-radius: 0 0 4px 4px;
  396. transition: max-height 0.3s ease;
  397. overflow: visible;
  398. padding: 4px;
  399. }
  400. .section-content.collapsed {
  401. display: none;
  402. }
  403. .section-content table {
  404. margin: 0;
  405. border: none;
  406. }