/*
 *  (c) 2000-2025 deviantART, Inc. All rights reserved.
 */
/*
@@require cssms/lib/survival.css -- need it first, so its padding rules don't override these ones
@@include cssms/lib/mixins/css3.css
*/
#forum,
#thread {
    background: url(/minish/main/bbg.gif) repeat-x top #D3DfD2;
    padding:  20px;
}
div.forum-header {
    margin-bottom: 10px;
    position: relative;
}
#forum div.forum-header h1,
#thread div.forum-header h1 {
    color: #2c3635;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5);
    line-height: 19px; /* Fudge to make title line up vertically may not be consistent across all browsers but looks slightly better in Webkit */
}

.forum-search-bar {
    float: left;
    padding: 5px 0 0 11px;
}
.forum-search-bar.forum-search-bar-right {
    float: none;
    position: absolute;
    right: 0;
    bottom: 0;
    padding: 0 5px 0 11px;
}
.forum-search-bar.forum-search-bar-left input#searchInput{
    width: 210px;
}

#thread .forum-header .catpath {
    padding-left: 0;
}

#thread .forum-header .catpath a {
    text-decoration: none;
}
#thread .forum-header .catpath a:hover {
    text-decoration: underline;
    color: #196BA7;
}

.forum-status-box {
    padding: 9px;
    background: #c6d4c3;
    border: 1px solid #B8C7B3;
    border-radius: 3px;
    box-shadow:0px 1px 1px rgba(255, 255, 255, 0.3);
    position: relative;
}
.forum-status-box span {
    display: block;
    text-shadow: 0 1px 1px rgba(255, 255, 255, 0.5);
    font-size: 11px;
    margin:  1px 0 1px 25px;
}
.forum-status-box span.forum-status-question {
    font-weight: bold;
    color: #2c3635;
}
body.gruze div.bubbleview .forum-status-box span a {
    color: #196BA7;
}
.forum-status-box .i1 {
    display: block;
    position: absolute;
    top: 6px;
    left: 6px;
    width: 25px;
    height: 25px;
    background: url(/minish/gruzecontrol/icons-gruser.gif?38) 0 0 no-repeat;
    overflow:  hidden;
}

body.gruze div.bubbleview p.forum-motd, body.gruze div.bubbleview p.forum-infobox {
    margin:15px 0;
    border:1px solid #a6b2a6;
    background:#edefcf;
    border-radius:4px;
    color:#787;
    padding:11px 15px;
    font-weight:bold;
}

body.gruze div.bubbleview p.forum-motd a, body.gruze div.bubbleview p.forum-infobox a {
    color:#196ba7;
}

#output #forum .talk-post .previewbox, 
#output #forum .talk .text {
    background-color: #D9E5D6;
}
table.fora {
    margin-bottom:8em;
}
table.fora th strong,
table.forum th strong {
    display:block;
    text-transform:uppercase;
    font-size:7.5pt;
    font-weight:bold;
    padding:12px 12px 3px 0;
    letter-spacing: 0.5px;
}
body.deviant table.fora th strong,
body.deviant table.forum th strong {
    color:#6C7F77;
}
table.forum th.f {
    padding-bottom:12px;
}
table.fora th.super strong {
    padding-left:12px;
}
table.fora th.super,
table.fora td.super,
table.forum th.super,
table.forum td.super {
    border-left:4px solid #EAF2EE;
}
body.gruze table tr th.super {
    border-left-color: transparent;
}
table.fora tr.head td {
    padding:12px 0 2px 0;
}
table.fora td.f,
table.forum td.f {
    background:#DEE8E5;
    padding:4px 12px;
    font-size:8.25pt;
    border-bottom:4px solid #D3DFD2;
}
body.deviant table.fora td.f,
body.deviant table.forum td.f {
    background:#AFBBB0;
    border-color:#BAC5BA;
    vertical-align: middle;
}
body.deviant table.fora th.super,
body.deviant table.fora td.super,
body.deviant table.forum th.super,
body.deviant table.forum td.super {
    border-color:#BAC5BA;
}
body.gruze table.fora th.f,
body.gruze table.forum th.f {
    padding-bottom: 0;
}
body.gruze table.forum td.f,
body.gruze table.fora td.f {
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
}
body.gruze table.forum td.bl,
body.gruze table.fora td.bl {
    border-bottom-left-radius:12px;
    border-top-left-radius:12px;
    border-left: 4px solid transparent;
}
body.gruze table.forum td.br,
body.gruze table.fora td.br {
    border-bottom-right-radius:12px;
    border-top-right-radius:12px;
    border-right: 4px solid transparent;
}
body.gruze table.fora span.light a.u,
body.gruze table.fora span.light {
    color:#6C7F77;
}
table.forum td.np {
    padding-left:0;
    border-left:none;
}
table.forum th.np strong {
    padding-left:0;
    padding-right:0;
    border-left:none;
}
/*  For some reason body-gruze.css overrides forum table colors with !important...
    this means specificity WAR
*/
body.gruze table.forum tr.sticky td {
    background-color:#BBCBB2;
}
body.deviant table.forum tr.sticky td {
    background-color:#A1B1A3;
}

body.gruze table.forum tr.sticky td.d-topic a,
body.deviant table.forum tr.sticky td.d-topic a {
    font-weight: bold;
}

body.gruze table.fora tr.forum-teaser td {
    opacity: 0.4;
    cursor: pointer;
}

table.fora td.f a.a,
table.fora td.f a.h,
table.forum td.f a.a,
table.forum td.f a.h {
    font-size:9pt;
}
table.fora td.super,
table.forum td.super {
    background:#D3E0DC;
}
body.deviant table.fora td.super,
body.deviant table.forum td.super {
    color:#2C3635;
    background:#AAB6AB;
}
div.bubble {
    border-radius:6px;
    background:#C8D6C6;
    font-size:11pt;
    padding:4px 8px;
}
div.bubbledark {
    background: #C0D0BE;
}
div.forum-no-activity {
    background:  #C1D1BC;
    border-radius: 6px;
    padding: 12px;
    font-size: 15px;
    color: #999;
    font-weight: bold;
    text-align: center;
    margin: 20px 0;
}
a.forum-signup {
    line-height: 48px;
}

/* Forum search results page styles. */
.searchResults .searchResultBar {
    color: #4f6153;
    font-weight: bold;
    margin-top: 1px;
}

.searchResults .searchResultBar .deemph {
    color: #6e8d71;
    font-weight: normal;
}

body #output .searchResults .forum-breadcrumbs {
    font-weight: normal;
}

body #output .searchResults .forum-breadcrumbs a.h {
    color: #6e8d71;
    text-decoration: none;
}

body #output .searchResults .forum-breadcrumbs a.h:hover, body #output .searchResults .forum-breadcrumbs a.h:last-child:hover {
    color: #196ba7;
    text-decoration: underline;
}

body #output .searchResults .forum-breadcrumbs a.h:last-child {
    color: #4f6153;
    font-weight: bold;
}

.searchResults .searchResultBar img {
    vertical-align: -3px;
    height: 17px;
    width: 17px;
}

.searchResults table.forum th.f {
    padding-bottom: 3px;
}

.searchResults table.forum th strong {
    padding-top: 0;
}

.searchResults tr.thread td:first-child {
    border-top-left-radius: 12px;
    border-bottom-left-radius: 12px;
    padding-left: 15px;
    width: 25px;
}

.searchResults tr.thread td:last-child {
    border-top-right-radius: 12px;
    border-bottom-right-radius: 12px;
}

#thread .section-block table {
    width: 80%;
    margin: auto;
}

#thread #commentbody {
    width: 80%;
    height: 205px;
}

#thread #commentsubject {
    width: 100%;
}

.forum_sidebar {
    width:300px;
    float:right;
}
.forum_root .forum_sidebar {
    margin-top:70px;
}
.forum_threadlist .forum_sidebar {
    margin-top: 90px;
}
.forum_thread .forum_sidebar {
    margin-top: 40px;
}

.forum_sidebar p {
    line-height:1.5em;
}
.forum_sidebar .close-thread {
    cursor:pointer;
    display: block;
}
.forum_sidebar .close-thread i {
    background:transparent url(/minish/messages/neutral-x.gif) repeat-x scroll left top;
    border:0 none;
    display:inline-block;
    width:15px;
    height:15px;
    outline: none;
    margin-left:-10px;
    margin-bottom:-3px;
}

.forum_sidebar .close-thread-author-ban {
    display: block;
}

.forum_content {
    margin-right:326px;

    & .image-comments-closed {
        margin-bottom: 30px;
    }
}

.forum_popularthreads {
    margin-top:1em;
}

.forum_popularthread {
    color: #8c9b8c;
    line-height: 1.5em;
    margin-bottom: 0.75em;
    padding-bottom: 0.75em;
    border-bottom: 1px solid #d0d0d0;
}

body.gruze div.bubbleview .forum_popularthread a.thread {
    font-weight:bold;
    color: #0f729c;
}

.forum_popularthread a.u,
.forum_popularthread span {
    color: #597465;
}

.forum_popularthread span.reply-count {
    background: url("/minish/submit/forum-comment-icon.png") no-repeat 0 3px;
    padding-left: 17px;
}

.forum_uplift_topic {
    margin:0 auto;
}
.forum_uplift_topic .topic_username {
    font-size:16px;
    line-height:25px;
}
.forum_uplift_topic .topic_username i.i1337 img {
    width:25px;
    height:25px;
    margin:0;
    vertical-align:middle;
}
body.gruze .forum_uplift_topic .topic_username a {
    color:#337287;
    font-weight:bold;
}
.forum_uplift_topic label {
    font-weight:bold;
    display:block;
    font-size:0.9em;
    margin:12px 0 3px;
    width:50%;
}
body.gruze .forum_uplift_topic a.commentfaq {
    float:right;
    margin:12px 0 3px;
    font-size:0.9em;
    color:#337287;
}
body.gruze .forum_uplift_topic a.emoticons {
    font-size:0.9em;
    color:#337287;
}
.forum_uplift_topic #commentsubject,
.forum_uplift_topic .commentbodywrapper {
    border-radius:3px;
    box-shadow:0 1px rgba(255, 255, 255, 0.95), 0 2px 4px rgba(0,0,0,0.2) inset;
    border:1px solid #898;
    padding:4px;
}
.forum_uplift_topic .commentbodywrapper {
    background:white;
    padding:0;
    min-height:255px;
}
#thread .forum_uplift_topic #commentbody,
#thread .forum_uplift_topic .commentbodywrapper .writer,
#thread .forum_uplift_topic .commentwriter-underlay,
#thread .forum_uplift_topic .previewcontainer {
    margin:4px 0 4px 4px;
    padding:2px 3px;
    border:0;
    min-height:205px;
    background-color:transparent;
}
#thread .forum_uplift_topic .drawPlz .topbar {
    background-color:transparent;
    margin:0 1%;
}
.forum_uplift_topic #commenticon {
    list-style:none;
    padding:0 20px 0 0;
    margin:0;

    &:after {
        content: '';
        display: block;
        clear: both;
    }
}
.forum_uplift_topic #commenticon li {
    float:left;
    text-align:center;
    width:25px;
    height:25px;
    line-height:25px;
    overflow:hidden;
    padding:5px;
    margin:0 5px 5px 0;
    border:1px solid #c4d1c5;
    border-radius:3px;
    background:#d8e4d9;
    cursor:pointer;
}
.forum_uplift_topic #commenticon li:hover {
    background:#c5d2c6;
}
.forum_uplift_topic #commenticon li.active {
    border:2px solid #136aa4;
    background:#c5d2c6;
    margin:-1px 4px 4px -1px;
}
.forum_uplift_topic #commenticon li input {
    display:none;
}
.forum_uplift_topic .commentoptions {
    clear:left;
    padding-top:20px;
}
.forum_uplift_topic .smbutton {
    margin:20px 10px 20px 0;
}

div.errorview {
    background-color: none;
    margin-top: 20px;
    margin-bottom: 20px;
}

.round-top {
    border-top-left-radius: 5px;
    border-top-right-radius: 5px;
}

.round-bottom {
    border-bottom-left-radius: 5px;
    border-bottom-right-radius: 5px;
}

@media (min-width: 600px) {
    .forum_uplift_topic {
        width:550px;
    }
    .forum_uplift_topic .commentbodywrapper {
        width:542px;
    }
    #thread .forum_uplift_topic #commentbody,
    #thread .forum_uplift_topic .commentbodywrapper .writer,
    #thread .forum_uplift_topic .commentwriter-underlay,
    #thread .forum_uplift_topic .previewcontainer {
        width:526px;
    }
}

/*
@@require cssms/lib/survival.css
*/

body.deviant .bubbleview a {
    color:#2C3635;
}
body.deviant .bubbleview a.a,
body.deviant .bubbleview .alink a {
    color:#196BA7;
}
body.deviant .bubbleview h1,
body.deviant .bubbleview h2,
body.deviant .bubbleview h3,
body.deviant .bubbleview h4,
body.deviant .bubbleview h1 a,
body.deviant .bubbleview h2 a,
body.deviant .bubbleview h3 a,
body.deviant .bubbleview h4 a {
    color:#2C3635;
}

body.deviant .bubbleview {
    background-color:#BAC5BA;
    color:#393D3C;
}
/*body.deviant .bubbleview td {
    color:#393D3C;
}*/
body.deviant i.c {
    border-color:#BAC5BA;
}
body.deviant i.c b {
    background:#BAC5BA;
}


/* legacy */
body.deviant #output .bubbleview .catbar {
    background:transparent url(/minish/main/bg-bubblb3.gif) repeat-x bottom left;
    border-top-color:#BEC9BF;
}

/* misc */
body.deviant .bubbleview .box,
body.deviant .bubbleview .comments .thought,
body.deviant .bubbleview .comments .nav span.shadow span,
body.deviant .bubbleview .pollpole {
    border-color:#92A399;
}
body.deviant .talk .text i.dd i {
    border-bottom-color:#BAC5BA;
}
body.deviant .bubbleview .box .boxtop,
body.deviant .bubbleview .collapsed-thought {
    background:#92A399;
}
body.deviant .bubbleview ul.list li.a,
body.deviant .bubbleview .altview,
body.deviant .bubbleview tr.a td {
    background:#AFBCB0;
}
body.deviant .bubbleview #browsebar1 {
    border-color:#94A09B;
}
body.deviant .bubbleview #browsebar2 {
    background:#ABB7B0;
}

/* Fixes for chat, these old style mess with its mojo */
body.deviant #output .bubbleview .catbar.chat {
    background: #C5D3C3 url(/minish/main/bg-bubblb2.gif) repeat-x bottom left;
    color: #414D4C;
    padding: 7px 15px 9px 15px;
    position: relative;
    margin: -7px -15px 7px -15px;
    zoom: 1;
}
body.deviant .bubbleview.chat {
    padding:7px 15px;
    background:#D6DED4;
}

/* polls */
div.poller {
    width:304px;
    white-space:nowrap;
    margin-bottom:2em;
}
div.box div.poller {
    font-size:8.25pt;
    white-space:normal;
}
div.pollpole {
    border:2px solid;
    padding:2px;
    text-indent:-3em;
    margin:8px 0 2px 0;
}

/* full-page polls */
div.bubbleview.full-page-poll {
    div.innerbubble {
        display: block;
        /* spread over the whole bubble to make the table go from edge to edge */
        margin:-7px -15px 12px;
        padding-top: 16px;
        padding-bottom: 16px;
    }
    table.full {
        width: 100%;
    }
    table.l {
        text-align:left;
    }
    table.c {
        text-align:center;
    }
    table.r {
        text-align:right;
    }
    table.zebra {
        font-size:10pt;
        border-collapse: collapse;
    }
    table.zebra tr {
        line-height: 2em;
    }
    table.zebra tr.odd {
        background-color: #edf4f1;        
    }
    table.zebra tr.even {
        background-color: #dee4db;
    }
    table.zebra td.date {
        width: 200px;
        color: #95AA93;
        font-weight: normal;
        font-size:9pt;
    }
    
    span.pollicon {
        float:left;
        background:transparent url(/styles/minimal/minish/icons-messages.gif) no-repeat scroll -279px 2px;
        height:26px;
        width:30px;
        top: 1px;
    }
    table.zebra td.title {
        position:relative;
        padding-left: 50px;
    }    

    div.poll_form {max-width: 700px; margin: 0 auto; text-align: center;}
    div.poll_form div.result_bars {width: 300px; margin: 0 auto; text-align: left;}
    div.poll_form h2 { padding: 12px 0 16px 0; }
    div.poll_form div.vote_result { float:right;margin:2px 8px 0px 0px;}
    div.poll_form div.results { max-width: 440px; margin:10px auto; color: #2e3a39;}
    div.poll_form div.result_bars span.votenum { color: #2e3a39; }
    div.result_bars div.poll-bar {border:0px solid;padding:4px 2px 4px 2px;text-indent:-3em;_text-indent:0;margin:8px 0 2px 0;border-left-color:#596b6a;background-color:#a2b2a9;color:#D6F8EB;position:relative;zoom:1;overflow:visible}
    div.result_bars div.poll-bar span {_position:relative;_left:-3em}
}

div.switcher div.switch,
div.switcher span.switch {
    display:none;
}
div.switcher span.active {
    display:inline
}
div.switcher div.active {
    display:block;
}

div.flex-top,
dt.flex-top {
    position:relative;
    z-index:10;
}
div.flex-fill,
dd.flex-fill {
    position:absolute;
    z-index:5;
    left:0;
    width:100%;
}
div.flex-bottom,
dd.flex-bottom {
    position:absolute;
    z-index:10;
    width:100%;
    bottom:0;
}

div.iconleft, div.iconright {
    position:relative;
    min-height:50px;
}
div.iconleft {
    padding-left:62px;
}
div.iconright {
    padding-right:62px;
}
div.iconleft img.avatar,
div.iconright img.avatar {
    position:absolute;
    top:0;
    left:0;
}
div.iconright img.avatar {
    left:auto;
    right:0;
}


/* Helper mixins */
.colormixin(@color:false) when not (@color=false) {color: @color;}
.bgcolormixin(@color:false) when not (@color=false) {background-color: @color;}
.bordercolormixin(@color:false) when not (@color=false) {border-color: @color;}

.widthmixin(@width:false) when not (@width=false) {width: @width;}
.minwidthmixin(@width:false) when not (@width=false) {min-width: @width;}
.maxwidthmixin(@width:false) when not (@width=false) {max-width: @width;}

.heightmixin(@height:false) when not (@height=false) {height: @height;}
.minheightmixin(@height:false) when not (@height=false) {min-height: @height;}
.maxheightmixin(@height:false) when not (@height=false) {max-height: @height;}

/* Helper variable for retina media queries */
@retina : ~"(-webkit-min-device-pixel-ratio: 2), (min--moz-device-pixel-ratio: 2), (min-device-pixel-ratio: 2), (min-resolution: 2dppx), (min-resolution: 192dpi)";

/*
 * helper function for .linear-gradient
 * @encode - string of svg xml
 */
.base64DataUriBackground (@encode, @type: ~"image/svg+xml") {
    @dataUriPrefix: ~"url(data:@{type};base64,";
    @dataUriSuffix: ~")";
 
    // because our lessc doesn't give access to btoa()
    // we have to make our own
    @b64DataUri: ~`(function(a,b,c){function e(a){a=a.replace(/\r\n/g,'\n');var b='';for(var c=0;c<a.length;c++){var d=a.charCodeAt(c);if(d<128){b+=String.fromCharCode(d)}else if(d>127&&d<2048){b+=String.fromCharCode(d>>6|192);b+=String.fromCharCode(d&63|128)}else{b+=String.fromCharCode(d>>12|224);b+=String.fromCharCode(d>>6&63|128);b+=String.fromCharCode(d&63|128)}}return b}function f(a){var b='';var c,f,g,h,i,j,l;var m=0;a=e(a);while(m<a.length){c=a.charCodeAt(m++);f=a.charCodeAt(m++);g=a.charCodeAt(m++);h=c>>2;i=(c&3)<<4|f>>4;j=(f&15)<<2|g>>6;l=g&63;if(isNaN(f)){j=l=64}else if(isNaN(g)){l=64}b=b+d.charAt(h)+d.charAt(i)+d.charAt(j)+d.charAt(l)}return b}var d='ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';return a+f(b)+c})('@{dataUriPrefix}','@{encode}','@{dataUriSuffix}')`;
 
    background: @b64DataUri;
}

/*
 * @angle - 1st param (eg 45deg, top, to left bottom)
 * @legacy_color - Color if no gradient at all is available
 * @ie_gradient_type - 0 (vertical) or 1 (horizontal).  If anybody wants to write a filter to deduce this 
 *                     angle, have at it
 */
.linear-gradient(@start_color, @end_color) {
    .linear-gradient(top, @start_color, @end_color, @start_color);
}
.linear-gradient(@angle, @start_color, @end_color) {
    .linear-gradient(@angle, @start_color, @end_color, @start_color);
}
.linear-gradient(@angle, @start_color, @end_color, @legacy_color: @start_color, @ie_gradient_type: 0) {
    @svg: ~'<?xml version="1.0" ?><svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%" viewBox="0 0 1 1" preserveAspectRatio="none"><linearGradient id="grad-ucgg-generated" gradientUnits="userSpaceOnUse" x1="0%" y1="0%" x2="0%" y2="100%"><stop offset="0%" stop-color="@{start_color}" stop-opacity="1"/><stop offset="100%" stop-color="@{end_color}" stop-opacity="1"/></linearGradient><rect x="0" y="0" width="1" height="1" fill="url(#grad-ucgg-generated)" /></svg>';
 
    
    /* base background */
    background: @legacy_color;
    
    /* IE9 you so special */
    .ie.eq9 & {
        .base64DataUriBackground(@svg);
    }
    /* IE8 is the bad kind of special */
    .ie.lt9 & {
        filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='@{start_color}', endColorstr='@{end_color}',GradientType=@ie_gradient_type );
    }
    
    /* hooray modern browsers */
    background: -webkit-linear-gradient(@angle, @start_color, @end_color);
    background: -moz-linear-gradient(@angle, @start_color, @end_color);
    background: linear-gradient(@angle, @start_color, @end_color);
}

.linear-gradient-stops(@angle, @legacy_start_color, @legacy_end_color, @legacy_color, @rest...) 
{
    @svg: ~'<?xml version="1.0" ?><svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%" viewBox="0 0 1 1" preserveAspectRatio="none"><linearGradient id="grad-ucgg-generated" gradientUnits="userSpaceOnUse" x1="0%" y1="0%" x2="0%" y2="100%"><stop offset="0%" stop-color="@{legacy_start_color}" stop-opacity="1"/><stop offset="100%" stop-color="@{legacy_end_color}" stop-opacity="1"/></linearGradient><rect x="0" y="0" width="1" height="1" fill="url(#grad-ucgg-generated)" /></svg>';
 
    
    /* base background */
    background: @legacy_color;
    
    /* IE9 you so special */
    .ie.eq9 & {
        .base64DataUriBackground(@svg);
    }
    /* IE8 is the bad kind of special */
    .ie.lt9 & {
        filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='@{legacy_start_color}', endColorstr='@{legacy_end_color}',GradientType=0 );
    }
    
    /* hooray modern browsers */
    background: -webkit-linear-gradient(@angle, @rest);
    background: -moz-linear-gradient(@angle, @rest);
    background: linear-gradient(@angle, @rest);
}

/*
 * This is not compatible with IE8, don't use it if you have to support old IE
 * 
 * @lhs - Left hand side (height, width, whatever)
 * @rhs - Right hand side, whatever your calculation is.  You probably need a ~
 *
 * Example: .calc(height, ~"100% - 50px")
 *
 * Note, using a guard because less doesn't seem to like using a variable for lhs
 * Annoying, but don't know what else to do
 *
 * http://caniuse.com/calc
 */
.calc(@lhs, @rhs) when (@lhs = width) {
    width: -webkit-calc(@rhs);
    width: calc(@rhs);
}
.calc(@lhs, @rhs) when (@lhs = height) {
    height: -webkit-calc(@rhs);
    height: calc(@rhs);
}
.calc(@lhs, @rhs) when (@lhs = left) {
    left: -webkit-calc(@rhs);
    left: calc(@rhs);
}
.calc(@lhs, @rhs) when (@lhs = right) {
    right: -webkit-calc(@rhs);
    right: calc(@rhs);
}
.calc(@lhs, @rhs) when (@lhs = top) {
    top: -webkit-calc(@rhs);
    top: calc(@rhs);
}
.calc(@lhs, @rhs) when (@lhs = bottom) {
    bottom: -webkit-calc(@rhs);
    bottom: calc(@rhs);
}
.calc(@lhs, @rhs) when (@lhs = min-width) {
    min-width: -webkit-calc(@rhs);
    min-width: calc(@rhs);
}
.calc(@lhs, @rhs) when (@lhs = max-width) {
    max-width: -webkit-calc(@rhs);
    max-width: calc(@rhs);
}
.calc(@lhs, @rhs) when (@lhs = min-height) {
    min-height: -webkit-calc(@rhs);
    min-height: calc(@rhs);
}
.calc(@lhs, @rhs) when (@lhs = max-height) {
    max-height: -webkit-calc(@rhs);
    max-height: calc(@rhs);
}


/*
 * Not compatible with IE8 or IE9 (nothing breaks, they just don't get transitions)
 */
.transition(@arg) {
    -moz-transition: @arg;
    -webkit-transition: @arg;
    transition: @arg;
}

.transition(@transition, @duration, @timingFunction: ease-in-out ) when (@transition = transform) {
    -webkit-transition: -webkit-transform @duration @timingFunction;
    -moz-transition: -moz-transform @duration @timingFunction;
    -ms-transition: -ms-transform @duration @timingFunction;
    transition: transform @duration @timingFunction;
}

.animation (@name, @duration: 300ms, @delay: 0, @ease: ease, @iterationCount: 1) {
    -webkit-animation: @name @duration @delay @ease;
    -moz-animation:    @name @duration @delay @ease;
    -ms-animation:     @name @duration @delay @ease;
    animation-iteration-count: @iterationCount;
    -webkit-animation-iteration-count: @iterationCount;
    -moz-animation-iteration-count: @iterationCount;
}

.transition-delay(@arg) {
    -webkit-transition-delay: @arg;
    -moz-transition-delay: @arg;
    -o-transition-delay: @arg;
    transition-delay: @arg;
}

/*
 * Not supported in <=IE8
 */
.transform(@arg) {
    -ms-transform: @arg;
    -webkit-transform: @arg;
    transform: @arg;
}

.transform-scale(@arg) {
    -ms-zoom: @arg;
    -ms-transform: scale(@arg);
    -webkit-transform: scale(@arg);
    transform: scale(@arg);
}

.transform-origin(@arg) {
    -ms-transform-origin: @arg;
    -moz-transform-origin: @arg;
    -webkit-transform-origin: @arg;
    transform-origin: @arg;
}

.box-sizing(@arg) {
    -moz-box-sizing: @arg;
    -webkit-box-sizing: @arg;
    box-sizing: @arg;
}

.filter(@arg) {
    -ms-filter: @arg;
    -moz-filter: @arg;
    -webkit-filter: @arg;
    filter: @arg;
}

.user-select(@arg) {
    -ms-user-select: @arg;
    -moz-user-select: @arg;
    -webkit-user-select: @arg;
    user-select: @arg;
}

.backface-visibility(@arg) {
    -webkit-backface-visibility: @arg;
    backface-visibility: @arg;
}

.perspective(@arg) {
    -webkit-perspective: @arg;
    perspective: @arg;
}

.cursor-zoom-in(@arg) {
    cursor: @arg;
    cursor: -webkit-zoom-in;
    cursor: -moz-zoom-in;
}

.cursor-zoom-out(@arg) {
    cursor: @arg;
    cursor: -webkit-zoom-out;
    cursor: -moz-zoom-out;
}

.appearance(@arg) {
    -webkit-appearance: @arg;
    -moz-appearance: @arg;
}

.text-size-adjust(@arg) {
    -webkit-text-size-adjust: @arg;
    -moz-text-size-adjust: @arg;
    -ms-text-size-adjust: @arg;
}

/* 
 *  Make something spin for infinite time, one rotation per @interval 
 *  example: .spin(3000ms)
*/
.spin(@interval) {
    -webkit-animation-name: spin;
    -webkit-animation-duration: @interval;
    -webkit-animation-iteration-count: infinite;
    -webkit-animation-timing-function: linear;
    -moz-animation-name: spin;
    -moz-animation-duration: @interval;
    -moz-animation-iteration-count: infinite;
    -moz-animation-timing-function: linear;
    -ms-animation-name: spin;
    -ms-animation-duration: @interval;
    -ms-animation-iteration-count: infinite;
    -ms-animation-timing-function: linear;
    animation-name: spin;
    animation-duration: @interval;
    animation-iteration-count: infinite;
    animation-timing-function: linear;

    @-ms-keyframes spin {
        from { -ms-transform: rotate(0deg); }
        to { -ms-transform: rotate(360deg); }
    }
    @-moz-keyframes spin {
        from { -moz-transform: rotate(0deg); }
        to { -moz-transform: rotate(360deg); }
    }
    @-webkit-keyframes spin {
        from { -webkit-transform: rotate(0deg); }
        to { -webkit-transform: rotate(360deg); }
    }
    @keyframes spin {
        from { transform:rotate(0deg); }
        to { transform:rotate(360deg); }
    }
}

/*
 * CSS3 multi-column layout.
 * Won't do anything for IE8 or 9.
 */
.column-count(@arg) {
    -moz-column-count: @arg;
    -webkit-column-count: @arg;
    column-count: @arg;
}
.column-width(@arg) {
    -moz-column-width: @arg;
    -webkit-column-width: @arg;
    column-width: @arg;
}
.column-gap(@arg) {
    -moz-column-gap: @arg;
    -webkit-column-gap: @arg;
    column-gap: @arg;
}
.column-rule(@arg) {
    -moz-column-rule: @arg;
    -webkit-column-rule: @arg;
    column-rule: @arg;
}

/*
 * Input placeholder text
 */
.placeholder-font-style(@style){
    &::-webkit-input-placeholder {
        font-style: @style;
    }
    &:-moz-placeholder {
        font-style: @style;
    }
    &::-moz-placeholder {
        font-style: @style;
    }
    &:-ms-input-placeholder {
        font-style: @style;
    }
}
.placeholder-color(@color: false, @bgcolor: false, @bordercolor: false){
    &::-webkit-input-placeholder {
        .colormixin(@color);
        .bgcolormixin(@bgcolor);
        .bordercolormixin(@bordercolor);
    }
    &:-moz-placeholder {
        .colormixin(@color);
        .bgcolormixin(@bgcolor);
        .bordercolormixin(@bordercolor);
    }
    &::-moz-placeholder {
        .colormixin(@color);
        .bgcolormixin(@bgcolor);
        .bordercolormixin(@bordercolor);
    }
    &:-ms-input-placeholder {
        .colormixin(@color);
        .bgcolormixin(@bgcolor);
        .bordercolormixin(@bordercolor);
    }
}

/* Full-screen mixin */
.full-screen-width(@width: false, @minwidth: false, @maxwidth: false) {
    &:-webkit-full-screen {
        .widthmixin(@width);
        .minwidthmixin(@minwidth);
        .maxwidthmixin(@maxwidth);
    }
    &:-moz-full-screen {
        .widthmixin(@width);
        .minwidthmixin(@minwidth);
        .maxwidthmixin(@maxwidth);
    }
    &:-ms-full-screen {
        .widthmixin(@width);
        .minwidthmixin(@minwidth);
        .maxwidthmixin(@maxwidth);
    }
    &:-o-full-screen {
        .widthmixin(@width);
        .minwidthmixin(@minwidth);
        .maxwidthmixin(@maxwidth);
    }
    &:full-screen {
        .widthmixin(@width);
        .minwidthmixin(@minwidth);
        .maxwidthmixin(@maxwidth);
    }
}
.full-screen-height(@height: false, @minheight: false, @maxheight: false) {
    &:-webkit-full-screen {
        .heightmixin(@height);
        .minheightmixin(@minheight);
        .maxheightmixin(@maxheight);
    }
    &:-moz-full-screen {
        .heightmixin(@height);
        .minheightmixin(@minheight);
        .maxheightmixin(@maxheight);
    }
    &:-ms-full-screen {
        .heightmixin(@height);
        .minheightmixin(@minheight);
        .maxheightmixin(@maxheight);
    }
    &:-o-full-screen {
        .heightmixin(@height);
        .minheightmixin(@minheight);
        .maxheightmixin(@maxheight);
    }
    &:full-screen {
        .heightmixin(@height);
        .minheightmixin(@minheight);
        .maxheightmixin(@maxheight);
    }
}

/* Text hyphenation */
.hyphenate(@style:auto) {
    -webkit-hyphens:@style;
       -moz-hyphens:@style;
        -ms-hyphens:@style;
            hyphens:@style;
}

.clearfix() {
    zoom:1;
    &:before, &:after{ 
        content:""; 
        display:table; 
    }
    &:after{ 
        clear: both; 
    }
}

.font-smoothing(@value: antialiased) when(@value = antialiased) {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
.font-smoothing(@value) when (@value = subpixel) {
    -webkit-font-smoothing: subpixel-antialiased;
    -moz-osx-font-smoothing: auto;
}

.font-default(@font-size: 14px, @line-height: 1.2, @font-weight: 300) {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    font-size: @font-size;
    line-height: @line-height;
    font-weight: @font-weight;
}

.font-face-calibre() {
    @font-face {
    font-family: 'Calibre-Bold';
        src: url('//st.deviantart.net/fonts/calibre-bold.otf') format('opentype');
        font-weight: normal;
        font-style: normal;
    }
    @font-face {
    font-family: 'Calibre-Semibold';
        src: url('//st.deviantart.net/fonts/calibre-semibold.otf') format('opentype');
        font-weight: normal;
        font-style: normal;
    }

    @font-face {
    font-family: 'Calibre-Light';
        src: url('//st.deviantart.net/fonts/calibre-light.otf') format('opentype');
        font-weight: normal;
        font-style: normal;
    }
}

.font-heading-bold(@font-size: 40px, @line-height: 1, @font-weight: 300) {
    font-family: 'Calibre-Bold';
    line-height: @line-height;
    font-weight: @font-weight;
    font-size: @font-size;
}

.flexbox() {
    /* order is important here */
    display: -webkit-box;      /* OLD - iOS <6, Safari 3.1-6 */
    display: -moz-box;         /* OLD - Firefox <19 */
    display: -ms-flexbox;      /* TWEENER - IE 10 */
    display: -webkit-flex;     /* NEW - Chrome */
    display: flex;             /* NEW, Opera 12.1, Firefox >20 */
}

.flex() {
    .flexbox();

    /* but not here */
    flex-wrap: wrap;
    -ms-flex-wrap: wrap;
    -moz-flex-wrap: wrap;
    -webkit-flex-wrap: wrap;
    flex-direction: row;
    -webkit-flex-direction:row;
    -moz-flex-direction:row;
    justify-content: flex-start;
    -webkit-justify-content:flex-start;
    -moz-justify-content:flex-start;
}
.flex-sizing(@size:1) {
    flex-grow: @size;
    -ms-flex-grow: @size;
    -moz-flex-grow: @size;
    -webkit-flex-grow:@size;
    flex-shrink: @size;
    -ms-flex-shrink: @size;
    -moz-flex-shrink: @size;
    -webkit-flex-shrink: @size;
}
.flex-center() {
    -webkit-box-pack: center; /* OLD - iOS <6, Safari 3.1-6 */
    -webkit-box-align: center;
    -moz-box-pack: center; /* OLD - Firefox <19 */
    -moz-box-align: center;
    -ms-flex-pack: center; /* TWEENER - IE 10 */
    -ms-flex-align: center;
    -webkit-justify-content: center; /* NEW - Chrome, Safari */
    -webkit-align-items: center;
    justify-content: center; /* NEW, Opera 12.1, Firefox >20 */
    align-items: center; 
}

.flexbox-inline() {
    display: -ms-inline-flex;
    display: -webkit-inline-flex;
    display: inline-flex;
}
.flex-direction(@value: row) {
    -webkit-flex-direction: @value;
    -ms-flex-direction: @value;
    flex-direction: @value;
}
.flex-grow(@value: 0) {
    -webkit-flex-grow: @value;
    -ms-flex-grow: @value;
    flex-grow: @value;
}
.flex-shrink(@value: 1) {
    -webkit-flex-shrink: @value;
    -ms-flex-shrink: @value;
    flex-shrink: @value;
}
.flex-justify(@value: flex-start) {
    -webkit-justify-content: @value;
    -ms-justify-content: @value;
    justify-content: @value;
}
.flex-align(@value: stretch) {
    -webkit-align-items: @value;
    -ms-align-items: @value;
    align-items: @value;
}
.flex-align-self(@value: auto) {
    -webkit-align-self: @value;
    -ms-align-self: @value;
    align-self: @value;
}
.flex-wrap(@value: wrap) {
    -webkit-flex-wrap: @value;
    -ms-flex-wrap: @value;
    flex-wrap: @value;
}
.fit(@margin:0) {
    position: absolute;
    top: @margin;
    right: @margin;
    bottom: @margin;
    left: @margin;
}

.fit-fixed(@margin:0) {
    position: fixed;
    top: @margin;
    right: @margin;
    bottom: @margin;
    left: @margin;
}

.transition-cubic-bezier(@property: all, @duration: 0.2s) {
    .transition(@property @duration cubic-bezier(0, 0, 0.58, 1));
}

/*
 * Push lately to have greyscale interfaces.
 * UI likes to think in terms of % grey, so they make mocks with
 * rgba(0,0,0, .74) for 74% grey.
 * This style uses more css room, requires more processing cycles from the browser's paint, and is dangerous
 * if underlying element is ever changed to something other than white.
 *
 * Now you can just do .foo { .grey(74%); color:@grey; }
 */

.grey(@percentage) {
    @grey: darken(#fff, 100% - @percentage);
}


/* Old brand colors */
.brandcolors() {
    @primary-green: #0FCC47;
    @primary-teal: #41CFC7;
    @primary-orange: #F75908;
    @primary-magenta: #ED145A;
    @primary-lightgreen: #BDD023;
    @primary-darkgreen: #026D20;

    @grey1: #111;
    @grey2: #242626;
    @grey3: #2F3131;
    @grey4: #323232;
    @grey5: #363636;
    @grey6: #474747;
    @grey7: #555;
    @grey8: #575757;
    @grey9: #666;
    @grey10: #6F6F6F;
    @grey11: #727272;
    @grey12: #828282;
    @grey13: #999;
    @grey14: #909090;
    @grey15: #CBCBCB;
    @pale-grey: #F2F2F2;

    @black-alpha1: rgba(0,0,0,0.5);
    @black-alpha2: rgba(0,0,0,0.2);

    @white-alpha1: rgba(0,0,0,0.8);
    @white-alpha2: rgba(0,0,0,0.5);
    @white-alpha3: rgba(0,0,0,0.3);
    @white-alpha4: rgba(0,0,0,0.2);
    @white-alpha5: rgba(0,0,0,0.1);
    @white-alpha6: rgba(0,0,0,0.07);

    @list-level-0: #19252C;
    @list-level-1: #273943;
    @list-level-2: #324855;
    @list-level-3: #455C69;
}

/* New brand colors */
.11-14-brandcolors() {
    /* Used by the header */
    @brand-green: #05CC47;
    @header-green: #475C4D;
    @dark-header-green: #46584A;
    @border-green: #38463B;
    @subheader-green: #3D4F42;
    @submit-green: #5FAC75;
    @menu-grey: #313836;
    @hover-blue: #508FA3;

    /* Colors from the brand guidelines */

    @black: #000;
    @grey1: #181A1B;
    @grey2: #4F5254;
    @grey3: #7D8080;
    @grey4: #F2F2F2;
    @white: #FFF;
    @darker-grey: #181A1B;
    @pale-grey: #F2F2F2;


    @blue1: #1F3833;
    @blue2: #36807A;
    @blue3: #40CFC7;
    @blue4: #D4F5F2;

    @green1: #1F3626;
    @green2: #42704F;
    @green3: #4DC47D;
    @green4: #D4F5DE;

    @orange: #F7590A;


    @core-access-icon: #FFB35C;
    @core-plus-icon: #FF815F;
    @core-pro-icon: #E776FF;
    @core-pro-plus-icon: #FF94B4;
    @core-max-icon: #7579FF;


    @accent-orange: darken(@orange, 10%);
}


