style.css
ASCII text
1@import "/static/efficient-ui/MASTER.css"; 2 3:root { 4--gap-navbar: 1rem; 5--width-navbar-button: 0; 6--text-soft: #000000C0; 7--text-softer: #0000009A; 8--text-faint: #00000066; 9--text-softest: #00000033; 10--color-star: #FFC107; 11--color-shape-label: #0097A7; --color-shape-label-text: #ffffff; 12--shadow-card-inset: inset 0 3px 6px -4px rgba(0, 0, 0, 0.12), inset 0 3px 6px 0 rgba(0, 0, 0, 0.24), inset 0 1px 4px 0 rgba(0, 0, 0, 0.12); 13--1-star: #FF8079; 14--2-star: #FF8A65; 15--3-star: #FFAC1B; 16--4-star: #FBC02D; 17--5-star: #CDDC39; 18/*view-transition-name: root;*/ 19} 20 21nav { 22/*view-transition-name: nav;*/ 23} 24 25p { 26color: var(--text-soft); 27} 28 29iconify-icon { 30/* Material design icons are done in 24px, so we scale them to 1.5 as the default font size is 16px */ 31display: inline-block; 32width: 1em; 33height: 1em; 34font-size: 1.5em; 35} 36 37:is(#shape-selector, #shape-options) > button > iconify-icon { 38font-size: 2rem; 39} 40 41#annotation-zone, .annotation-zone { 42position: relative; 43user-select: none; 44overflow: hidden; 45} 46 47#annotation-image, .annotation-image { 48user-drag: none; 49-webkit-user-drag: none; 50image-rendering: pixelated; 51} 52 53#annotation-zone > svg, .annotation-zone > svg { 54z-index: 1; 55position: absolute; 56top: 0; 57left: 0; 58width: 100%; 59height: 100%; 60} 61 62.annotation-ruler { 63z-index: 2; 64position: absolute; 65top: 0; 66left: 0; 67background: var(--color-accent); 68display: none; 69} 70 71#annotation-ruler-horizontal, #annotation-ruler-horizontal-secondary { 72height: 1px; 73width: 100%; 74} 75 76#annotation-ruler-vertical, #annotation-ruler-vertical-secondary { 77width: 1px; 78height: 100%; 79} 80 81.shape { 82stroke: var(--color-accent); 83fill: var(--color-accent); 84fill-opacity: 0.1; 85stroke-width: 2px; 86vector-effect: non-scaling-stroke; 87pointer-events: auto; 88transition: filter 0.25s cubic-bezier(0.61, 1, 0.88, 1), 89fill-opacity 0.25s cubic-bezier(0.61, 1, 0.88, 1), 90stroke-width 0.25s cubic-bezier(0.61, 1, 0.88, 1); 91stroke-linecap: square; 92stroke-linejoin: miter; 93} 94 95.shape-polyline { 96fill: none; 97} 98 99.shape-point { 100stroke: var(--color-accent); 101stroke-width: 2px; 102fill-opacity: 1; 103r: 2; 104transition: r 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), 105stroke-width 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), 106filter 0.25s cubic-bezier(0.61, 1, 0.88, 1); 107} 108 109.shape.selected { 110fill-opacity: 0.2; 111stroke-width: 4px; 112filter: drop-shadow(0 0 2px var(--text-soft)); 113} 114 115.shape-point.selected { 116fill-opacity: 1; 117r: 6; 118stroke-width: 6px; 119} 120 121.shape-container, .shape-container-viewonly { 122pointer-events: none; 123} 124 125#annotation-helper-message { 126min-height: 2lh; 127} 128 129.shape-container-viewonly > .shape, .thumbnail-list > li .shape { 130fill: var(--color-info); 131stroke: var(--color-info); 132fill-opacity: 0; 133stroke-opacity: 0; 134transition: fill-opacity 0.25s cubic-bezier(0.61, 1, 0.88, 1), 135stroke-opacity 0.25s cubic-bezier(0.61, 1, 0.88, 1); 136} 137 138.shape-container-viewonly > .shape-polyline, .thumbnail-list > li .shape-polyline { 139fill: none; 140} 141 142.shape-container-viewonly > .shape-point, .thumbnail-list > li .shape-point { 143stroke: var(--color-info); 144transition: r 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), 145stroke-width 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), 146filter 0.25s cubic-bezier(0.61, 1, 0.88, 1); 147} 148 149.shape-label { 150position: absolute; 151font-weight: 500; 152color: var(--color-shape-label-text) !important; 153pointer-events: auto; 154height: 28px; 155padding-left: 8px; 156padding-right: 8px; 157display: flex; 158align-items: center; 159justify-content: center; 160background: var(--color-shape-label); 161width: max-content; 162box-shadow: var(--shadow-button); 163/* top-left corner is square to point to the shape */ 164border-radius: 0 16px 16px 16px; 165opacity: 0; 166transition: opacity 0.25s cubic-bezier(0.61, 1, 0.88, 1), 167transform 0.375s cubic-bezier(0.16, 1, 0.3, 1); 168transform: scale(0); 169transform-origin: top left; 170z-index: 3; 171text-decoration: none; 172} 173 174.shape-label:hover { 175text-decoration: underline; 176} 177 178/* Only show region parts when checkbox is checked */ 179#annotation-zone:has(+ x-buttonbox #show-objects:checked) > .shape-label { 180opacity: 1; 181transform: scale(1); 182} 183 184/* Hide points with a bubble */ 185#annotation-zone:has(+ x-buttonbox #show-objects:checked) > .shape-container-viewonly > .shape-point:has(+ foreignObject) { 186r: 0; 187border-width: 0; 188} 189 190#annotation-zone:has(+ x-buttonbox #show-shapes:checked) > .shape-container-viewonly > .shape { 191fill-opacity: 0.1; 192stroke-opacity: 1; 193} 194 195.thumbnail-list > li:is(:hover, :focus, :has(:focus)) .shape { 196fill-opacity: 0.2; 197stroke-opacity: 1; 198} 199 200/* Disabled for now, until there is more navigation that would benefit from transitions */ 201/* 202@view-transition { 203navigation: auto; 204} 205 206@keyframes move-out { 207from { 208transform: translateX(0%); 209} 210to { 211transform: translateX(-100%); 212} 213} 214 215@keyframes move-in { 216from { 217transform: translateX(100%); 218} 219to { 220transform: translateX(0%); 221} 222} 223 224@media (prefers-reduced-motion: no-preference) { 225::view-transition-old(root), 226::view-transition-new(root) { 227animation-duration: 0.25s; 228animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1); 229} 230 231::view-transition-old(root) { 232animation-name: move-out; 233} 234 235::view-transition-new(root) { 236animation-name: move-in; 237} 238} 239*/ 240 241.multi-select, .single-select { 242display: flex; 243flex-flow: column nowrap; 244overflow-y: scroll; 245box-shadow: var(--shadow-card-inset); 246padding: 16px; 247gap: 8px; 248} 249 250.licence-selection, .image-type-selection { 251display: flex; 252flex-flow: column nowrap; 253} 254 255.licence-selection-info, .image-type-selection-info { 256margin-left: calc(var(--size-checkbox) + var(--gap-label-checkbox)); 257/* Align with the checkbox above */ 258} 259 260.licence-selection-info > p, .image-type-selection-info > p { 261font-weight: 300; 262} 263 264.licence-logo { 265width: 128px; 266float: right; 267margin-left: 1ch; 268} 269 270.licence-title, .image-type-title { 271display: flex; 272justify-content: space-between; 273width: 100%; 274} 275 276.licence-title > .licence-name, .image-type-title > .image-type-name { 277font: var(--h5-font); 278font-weight: 400; 279} 280 281.icon-explainer { 282display: grid; 283gap: 4px 8px; 284grid-template-columns: auto 1fr; 285align-items: center; 286} 287 288.icon-explainer *:nth-child(even) { 289font-weight: 300; 290} 291 292.required-asterisk::after { 293content: "*"; 294color: var(--color-error); 295} 296 297small { 298/* BIG :D */ 299font-size: 1em; 300} 301 302#pagination { 303display: flex; 304gap: 1em; 305justify-content: center; 306align-items: center; 307font-size: 1.5em; 308font-weight: 600; 309flex: 1 0 auto; 310} 311 312#pagination > a { 313text-decoration: none; 314color: var(--color-accent-1); 315} 316 317#pagination-options > form { 318align-items: center; 319display: flex; 320gap: 1em; 321} 322 323#pagination-options { 324justify-content: center; 325align-items: center; 326gap: 1em; 327width: 100%; 328} 329 330.thumbnail-list { 331list-style: none; 332margin: 0 !important; 333display: grid; 334grid-template-columns: repeat(auto-fill, minmax(128px, 1fr)); 335gap: 16px; 336} 337 338.thumbnail-list > li { 339transition: transform 0.25s cubic-bezier(0.61, 1, 0.88, 1), 340box-shadow 0.25s cubic-bezier(0.61, 1, 0.88, 1); 341box-shadow: var(--shadow-card); 342background: var(--color-card); 343} 344 345.thumbnail-list > li > a, .thumbnail-list > li { 346display: flex; 347flex-direction: column; 348justify-content: space-between; 349height: 100%; 350} 351 352.thumbnail-list > li > .list-more { 353display: flex; 354justify-content: space-between; 355align-items: center; 356padding: 8px; 357} 358 359.thumbnail-list > li:is(:hover, :focus, :has(:focus)) { 360position: relative; 361transform: scale(1.5); 362z-index: 1; 363box-shadow: var(--shadow-card), 0 4px 32px rgba(0, 0, 0, 0.12), 0 4px 16px rgba(0, 0, 0, 0.08); 364} 365 366.thumbnail-list > li .list-detail { 367padding: 8px; 368display: block; 369} 370 371a.button { 372text-decoration: none; 373} 374 375dt { 376font-weight: 600; 377} 378 379dd { 380margin-left: 40px; 381} 382 383#mobile-navbar { 384display: none; 385} 386 387@media screen and (max-width: 576px) { 388#mobile-navbar { 389display: flex; 390} 391#desktop-navbar { 392display: none; 393} 394} 395 396#hamburger > nav { 397display: flex; 398flex-direction: column; 399gap: 1em; 400padding: var(--padding-card); 401padding-top: var(--padding-card-top); 402box-shadow: var(--shadow-card); 403background: var(--color-card); 404justify-content: space-between; 405width: clamp(240px, calc(100vw - 56px), 448px); 406} 407 408#hamburger > nav > ul { 409display: flex; 410flex-direction: column; 411gap: 1em; 412margin: 0; 413} 414 415#hamburger > nav > ul > li { 416display: flex; 417gap: var(--gap-label-checkbox); 418align-items: center; 419margin: 0; 420} 421 422#hamburger > nav > ul > li > a { 423text-decoration: none; 424color: var(--color-card-text); 425} 426 427.star-rating-container { 428display: flex; 429flex-direction: row-reverse; 430font-size: 1.25em; 431align-items: center; 432justify-content: flex-end; /* In this case, it means LEFT, not right, because of the row-reverse */ 433} 434 435.star-rating-container > input { 436width: 0 !important; 437height: 0 !important; 438visibility: hidden; 439} 440 441.star-rating-container > label { 442cursor: pointer; 443color: var(--text-softest); 444transition: color 0.25s cubic-bezier(0.37, 0, 0.63, 1), 445filter 0.25s cubic-bezier(0.37, 0, 0.63, 1); 446} 447 448.star-rating-container > label:hover, 449.star-rating-container > label:hover ~ label { 450color: var(--color-star); 451filter: drop-shadow(0 0 3px #00000040); 452} 453 454.star-rating-container > input:checked ~ label { 455color: var(--color-star); 456} 457 458.visually-hidden { 459position: absolute; 460width: 1px; 461height: 1px; 462box-sizing: content-box; 463margin: -1px; 464overflow: hidden; 465clip-path: inset(50%); 466border: 0; 467} 468 469.rating-list { 470display: grid; 471grid-auto-columns: 1fr; 472gap: 0.5rem; 473grid-template-columns: auto; 474list-style: none; 475margin: 0 !important; 476padding: 0; 477min-width: 50%; 478} 479 480.rating-list > li { 481grid-column-start: 1; 482height: 28px; 483padding: 4px 8px; 484display: flex; 485align-items: center; 486justify-content: space-between; 487gap: 0.5rch; 488border-radius: 0 4px 4px 0; 489margin: 0; 490} 491 492.rating-bar { 493display: flex; 494align-items: center; 495justify-content: flex-start; 496gap: 0.5rch; 497font-size: 1.25em; 498width: 100%; 499} 500 501.rating-bar > .rating-bar-segment { 502position: relative; 503width: 1em; 504height: 1em; 505clip-path: url(#star-clip); 506background: var(--text-softest); 507} 508 509.rating-bar > .rating-bar-segment > .rating-bar-filling { 510background: var(--color-star); 511height: 100%; 512position: absolute; 513top: 0; 514left: 0; 515} 516