3 The following CSS is consistent between example themes and should not be altered.
5 #colorbox, #cboxOverlay
, #cboxWrapper
{position:absolute
; top:0; left:0; z-index:9999; overflow:hidden
;}
6 #cboxWrapper {max-width:none
;}
7 #cboxOverlay{position:fixed
; width:100%; height:100%;}
8 #cboxMiddleLeft, #cboxBottomLeft
{clear:left
;}
9 #cboxContent{position:relative
;}
10 #cboxLoadedContent{overflow:auto
; -webkit-overflow-scrolling: touch
;}
12 #cboxLoadingOverlay, #cboxLoadingGraphic
{position:absolute
; top:0; left:0; width:100%; height:100%;}
13 #cboxPrevious, #cboxNext
, #cboxClose
, #cboxSlideshow
{cursor:pointer
;}
14 .cboxPhoto{float:left
; margin:auto
; border:0; display:block
; max-width:none
; -ms-interpolation-mode:bicubic
;}
15 .cboxIframe{width:100%; height:100%; display:block
; border:0; padding:0; margin:0;}
16 #colorbox, #cboxContent
, #cboxLoadedContent
{-webkit-box-sizing: content-box
;-moz-box-sizing: content-box
;box-sizing: content-box
;}
18 /* these elements are buttons, and may need to have additional styles reset to avoid unwanted base styles */
19 #cboxPrevious, #cboxNext
, #cboxSlideshow
, #cboxClose
{border:0; padding:0; margin:0; overflow:visible
; width:auto
; background:none
; }
20 /* avoid outlines on :active (mouseclick), but preserve outlines on :focus (tabbed navigating) */
21 #cboxPrevious:active
, #
cboxNext:active
, #
cboxSlideshow:active
, #
cboxClose:active
{outline:0;}
26 The following rules are ordered and tabbed in a way that represents the
27 order/nesting of the generated HTML, so that the structure easier to understand.
29 #cboxOverlay{background:#000000;}
31 #cboxTopLeft{width:10px; height:10px; background:#fff;}
32 #cboxTopRight{width:10px; height:10px; background:#fff;}
33 #cboxBottomLeft{width:10px; height:10px; background:#fff;}
34 #cboxBottomRight{width:10px; height:10px; background:#fff;}
35 #cboxMiddleLeft{width:10px; background:#fff;}
36 #cboxMiddleRight{width:10px; background:#fff;}
37 #cboxTopCenter{height:10px; background:#fff;}
38 #cboxBottomCenter{height:10px; background:#fff;}
39 #cboxContent{background:#fff;}
40 #cboxLoadedContent{margin:0 0 58px;}
41 #cboxTitle{position:absolute
; bottom:28px; right:0; text-align:right
; width:100%; color:#000; font-weight:bold
;font-size:0.9em;}
42 #cboxCurrent{position:absolute
; bottom:0px; right:0px; color:#666666; font-size:0.85em;}
43 #cboxPrevious{position:absolute
; bottom:4px; right:40px; background:url
(images/controls.png) -13px 0px no-repeat
; width:13px; height:13px; text-indent:-9999px;}
44 #cboxPrevious.hover
{background-position:-13px -13px;}
45 #cboxNext{position:absolute
; bottom:4px; right:60px; background:url
(images/controls.png) 0px 0px no-repeat
; width:13px; height:13px; text-indent:-9999px;}
46 #cboxNext.hover
{background-position:0px -13px;}
47 #cboxSlideshow{position:absolute
; bottom:0px; right:80px; color:#666666;font-size:0.85em;}
48 #cboxLoadingOverlay{background:#fff;}
49 #cboxLoadingGraphic{background:url
(images/loading.gif) center center no-repeat
;}
50 #cboxClose{position:absolute
; bottom:20px; left:0; background:url
(images/close.gif) 0px 0px no-repeat
; width:26px; height:26px; text-indent:-9999px;border:0}
53 The following fixes png-transparency for IE6.
54 It is also necessary for png-transparency in IE7 & IE8 to avoid 'black halos' with the fade transition
56 Since this method does not support CSS background-positioning, it is incompatible with CSS sprites.
57 Colorbox preloads navigation hover classes to account for this.
59 !! Important Note: AlphaImageLoader src paths are relative to the HTML document,
60 while regular CSS background images are relative to the CSS document.