h1, h2, h3, h4, h5 {
    font-family: "Helvetica Neue",Helvetica,Arial,sans-serif;
    margin: 0;
}
body {
    position: relative;
    padding-top: 60px;
}

/**
 * General style
 */
.well .form-actions {
    background: transparent;
    padding-bottom: 0;
}
.form-horizontal .control-group {
    margin-bottom: 10px;
}
form strong.read-only {
    display: inline-block;
    padding: 4px;
    line-height: 18px;
}
.loading {
    display: none;
    margin-left: 5px;
    color: #999;
}
.loading.active {
    display: inline-block;
}

ul.error {
    margin-bottom: 0;
}
.alert-flash {
    margin: 15px 0;
}

h1 {
    font-size: 220%;
    color: #222;
}
h2 {
    font-size: 170%;
    color: #333;
}
h3 {
    font-size: 140%;
    color: #444;
}
h4 {
    font-size: 120%;
    color: #555;
}


/**
 * Heading
 */
.heading {
    overflow: hidden;
    padding-bottom: 10px;
}
.heading h1, 
.heading h2, 
.heading h3, 
.heading h4 {
    display: inline-block;
} 
.heading .actions {
    display: inline-block;
    margin-left: 5px;
} 
.heading .actions a {
    display: inline-block;
    margin-left: 15px;
} 
.heading .actions a.btn {
    margin-top: -15px;
}
.heading .actions .split {
    font-weight: 300;
    color: #bbb;
    display: inline-block;
    margin-left: 15px;
}


/**
 *  Cardmakers
 */
#cardmakers {
    padding: 8px 0;
}
#cardmakers-wrapper .input-search {
    width: 140px;
}
#cardmakers-wrapper .btn {
    padding: 4px 10px; 
}
#cardmakers-tabs .nav {
    margin-bottom: 10px;
}
#cardmakers-tabs .tab-content .btn-toolbar {
    margin-top: 0;
}

/**
 * Actions
 */
table .actions {
    text-align: right;
}
table .actions a {
    text-decoration: underline;
    margin-left: 10px;
    display: inline-block;
}


/**
 * Simple links with left margin to be used in place of buttons
 */
.btn-link {
    margin-left: 15px;
    display: inline-block;
    vertical-align: baseline;
    text-decoration: underline;
}


dl.order dt {
    width: 130px;
    float: left;
    text-align: right;
    clear: left;
}
dl.order dd {
    padding-left: 140px;
    margin-left: 0;
    margin-bottom: 10px;
    min-height: 1.5em;
}
dl.order table {
    background: #fff;
}

/**
 * Layout
 */
.full .navbar .container {
    width: auto;
    padding: 0 20px;
}


/**
 * Body style
 */
body.backoffice .navbar-inner {
    background: #335;
}
body.backoffice .navbar .nav .active a {
    background-color: #557;
}

/**
 * Common styles
 */
.scrollable {
    height: 92px;
    overflow-y: scroll;
    border: 1px solid #ccc;
    padding: 0 4px;
    background-color: #fff;
    border-radius: 3px;
    -moz-border-radius: 3px;
    -webkit-border-radius: 3px;
}
.scrollable label {
    margin-bottom: 0;
}

/**
 * Template maker
 */
#template-general .control-group {
    margin: 0;
}
#template-name {
    width: 380px;
}
#template-form {
    margin: 0;
}
#template-form hr {
    margin: 0 0 8px 0;
}
#template-form #cancel {
    display: inline-block;
    padding: 4px 10px;
    vertical-align: middle;
}
#template-maker {
    position: relative;
}
#template-sidebar {
    float: left;
    width: 430px;
}
#template-fields {
    float: left;
    width: 178px;
}
#template-fields .control-label {
    display: none;
}
#template-properties {
    float: left;
    width: 238px;
    margin-left: 10px;
}
#template-viewport-wrapper {
    margin-left: 440px;
    width: auto;
}
#template-viewport {
    width: auto;
}

#template-fields {
    padding: 8px 0;
}
#template-fields .btn-toolbar {
    margin: 6px 14px 3px;
}
#template-fields .btn-toolbar .dropdown-toggle{
    -webkit-border-top-right-radius:0;
    -moz-border-radius-topright:0;
    border-top-right-radius:0;
    -webkit-border-bottom-right-radius:0;
    -moz-border-radius-bottomright:0;
    border-bottom-right-radius:0;
}
#template-fields .control-group {
    padding: 0 10px;
}
#template-properties {
    padding: 8px 0;
}
#template-properties .control-group {
    margin-bottom: 10px;
}
#template-properties .control-label {
    width: 20%;
}
#template-properties .controls {
    margin-left: 22%;
}
#template-properties .input-medium {
    width: 85%;
}
#template-properties textarea.input-medium {
    margin-left: -22%;
    width: 202px;
}
#template-properties .span50p .control-label {
    width: 40%;
}
#template-properties .span50p .controls {
    margin-left: 44%;
}

#template-viewport {
    background: #fff;
    border: 2px solid #ccc;
    height: 685px;
    overflow: scroll;
    position: relative;
}
#template-viewport.focused {
    border-color: #99F;
}
#template-viewport .background-wrapper {
    width: auto;
    margin: 0 auto;
    width: 1013px;
    height: 638px;
    z-index: 8;
    padding: 15px;
}
#template-viewport .background {
    background: #fff;
    width: 1013px;
    height: 638px;
    position: relative;
    -webkit-box-shadow: 0px 5px 30px 0px rgba(100, 100, 100, 0.5);
    -moz-box-shadow: 0px 5px 30px 0px rgba(100, 100, 100, 0.5);
    box-shadow: 0px 5px 30px 0px rgba(100, 100, 100, 0.5);
}
#template-viewport .background-wrapper.portrait {
    width: 638px;
    height: 1013px;
}
#template-viewport .background.portrait {
    width: 638px;
    height: 1013px;
}
#template-viewport .marker {
    position: absolute;
    overflow: hidden;
    z-index: 10;
}
#template-viewport .marker.active {
    z-index: 12;
}
#template-viewport .marker .inner {
    background: transparent;
    border: 1px dashed #ccc;
    overflow: hidden;
    cursor: move;
    line-height: normal;
}
#template-viewport .marker .inner.border {
    border: 2px solid #000;
}
#template-viewport .marker.active .inner {
    border-style: solid;
    border-color: #99f !important;
}
#template-viewport .marker.picture {
    overflow: visible;
}
#template-viewport .marker.picture .inner {
    z-index: 12;
    position: relative;
    background: url("../images/picture.png") 50% 50% #cdf no-repeat;
}
#template-viewport .marker .code {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
}
#template-viewport .marker .text {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
}
#template-maker .file-controls {
    clear: both;
    margin: 0 10px;
}


/**
 * Save message
 */
#save-message {
    display: inline-block;
    padding: 4px 10px;
    vertical-align: middle;
    float: right;
    text-align: right;
    color: #08C;
    font-weight: bold;
}

/**
 * Resizable
 */
.ui-resizable-handle {
    position: absolute;
    width: 100%;
    height: 100%;
}
.ui-resizable-handle:hover {
    background-color: #333;
    opacity: 0.3;
    filter:Alpha(opacity=30);
}
.ui-resizable-n {
    top: 0;
    left: 0;
    height: 5px;
    cursor: n-resize;
}
.ui-resizable-s {
    bottom: 0;
    left: 0;
    height: 5px;
    cursor: s-resize;
}
.ui-resizable-w {
    left: 0;
    top: 0;
    width: 5px;
    cursor: w-resize;
}
.ui-resizable-e {
    right: 0;
    top: 0;
    width: 5px;
    cursor: e-resize;
}
.ui-resizable-ne,
.ui-resizable-se,
.ui-resizable-sw,
.ui-resizable-nw {
    background-color: #333;
    opacity: 0.5;
    filter:Alpha(opacity=50);
}
.ui-resizable-ne {
    top: 0;
    right: 0;
    height: 15px;
    width: 15px;
    cursor: ne-resize;
}
.ui-resizable-se {
    bottom: 0;
    right: 0;
    height: 15px;
    width: 15px;
    cursor: se-resize;
}
.ui-resizable-sw {
    left: 0;
    bottom: 0;
    width: 15px;
    height: 15px;
    cursor: sw-resize;
}
.ui-resizable-nw {
    left: 0;
    top: 0;
    width: 15px;
    height: 15px;
    cursor: nw-resize;
}


.well .header {
    font-family: "Helvetica Neue",Helvetica,Arial,sans-serif;
    display: block;
    padding: 3px 15px;
    font-size: 11px;
    font-weight: bold;
    line-height: 18px;
    color: #999;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
}
.well hr {
    margin: 10px;
}
.well.white {
    background: #fff;
}

.span50p {
    width: 50%;
    float: left;
    margin: 0;
    padding: 0;
}
.input-micro {
    width: 40px;
}

/**
 * Color picker
 */
.btn-color img {
    display: inline-block;
    width: 14px;
    height: 14px;
    line-height: 14px;
    vertical-align: text-top;
}
.ui-colorpicker-dialog {
    z-index: 20;
}
#ui-colorpicker-inputs > div {
    margin-bottom: 5px;
    white-space: nowrap;
}
#ui-colorpicker-inputs input,
#ui-colorpicker-inputs select,
#ui-colorpicker-inputs textarea
{
    width: auto;
    max-width: 40px;
    padding: 2px;
    margin-bottom: 0;
}
#ui-colorpicker-inputs label {
    margin-bottom: 0;
    vertical-align: middle;
}

[class^="icon-extra-"],[class*=" icon-extra-"]{display:inline-block;width:14px;height:14px;line-height:14px;vertical-align:text-top;background-image:url("../img/glyphicons-halflings-extra.png");background-position:14px 14px;background-repeat:no-repeat;*margin-right:.3em;}[class^="icon-extra-"]:last-child,[class*=" icon-extra-"]:last-child{*margin-left:0;}
.icon-extra-underline {
    background-position: 0 0;
}
.icon-extra-text {
    background-position: -24px 0;
}
.icon-extra-background {
    background-position: -48px 0;
}
.icon-extra-bullet {
    background-position: -72px 0;
}
.icon-extra-white,
.nav-tabs > .active > a > [class^="icon-extra-"],
.nav-tabs > .active > a > [class*=" icon-extra-"],
.nav-pills > .active > a > [class^="icon-extra-"],
.nav-pills > .active > a > [class*=" icon-extra-"],
.nav-list > .active > a > [class^="icon-extra-"],
.nav-list > .active > a > [class*=" icon-extra-"],
.navbar-inverse .nav > .active > a > [class^="icon-extra-"],
.navbar-inverse .nav > .active > a > [class*=" icon-extra-"],
.dropdown-menu > li > a:hover > [class^="icon-extra-"],
.dropdown-menu > li > a:hover > [class*=" icon-extra-"],
.dropdown-menu > .active > a > [class^="icon-extra-"],
.dropdown-menu > .active > a > [class*=" icon-extra-"] {
    background-image: url("../img/glyphicons-halflings-extra-white.png");
}


/**
 * Uploader
 */
#form-background-uploader {
    position: absolute;
    left: -5000px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/*
 * Cardmaker
 */
#cardmaker-template-main {
    padding: 10px;
}
#cardmaker-form {
    margin-top: 10px;
    border: 2px solid #ccc;
    border-radius: 6px;
    background: #fff;
    padding: 15px 15px 60px 15px;
    min-height: 300px;
    position: relative;
}
#cardmaker-form .step {
    display: none;
}
#cardmaker-form h2 {
    margin-bottom: 10px;
}
#cardmaker-form .step.active {
    display: block;
}
#cardmaker-form .form-actions {
    position: absolute;
    bottom: 0;
    left: 0;
    padding: 15px 0;
    margin: 0;
    background: transparent;
    width: 100%;
    height: 30px;
    text-align: right;
}
#cardmaker-form .form-actions .next,
#cardmaker-form .form-actions .save {
    float: right;
    margin-right: 15px;
}
#cardmaker-form .form-actions .back {
    float: left;
    margin-left: 15px;
}
#cardmaker-form .template-preview {
    float: right;
    width: 410px;
    height: 200px;
    background: #efefef;
    border-radius: 5px;
}
#cardmaker-form .template-preview .inner {
    width: 200px;
    height: 200px;
    display: table-cell;
    text-align: center;
    vertical-align: middle;
}
#cardmaker-form .template-preview img {
    max-width: 90%;
    max-height: 90%;
}
#cardmaker-card-form input,
#cardmaker-card-form select,
#cardmaker-card-form textarea,
#cardmaker-card-form .uneditable-input {
    margin-bottom: 0;
}
#cardmaker-card-form #cancel {
    display: inline-block;
    padding: 4px 10px;
    vertical-align: middle;
}
#cardmaker-card-form .picture-wrapper {
    overflow: hidden;
    padding-bottom: 9px;
}
#cardmaker-card-form .picture {
    border: 1px solid #99f;
    width: 72px;
    height: 96px;
    background: url("../images/picture-small.png") 50% 50% #cdf no-repeat;
    float: left;
    margin-right: 10px;
}
#cardmaker-card-form .picture-button {
    
}
#cardmaker-template-form {
    margin-bottom: 0;
}
#cardmaker-card-form .step label.error {
    color: #933;
    font-size: 12px;
}
#cardmaker-card-form .control-group {
    margin-bottom: 9px;
}
#cardmaker-card-form .max-warning {
    display: block;
    font-size: 12px;
    color: #933;
    padding: 0 3px;
    margin-bottom: 3px;
}


/* Picture Dialog */
#picture-dialog {
    width: 730px;
    margin-left: -365px;
    margin-top: -290px;
}
#picture-dialog form {
    margin-bottom: 0;
}
#picture-dialog .modal-body {
    max-height: 500px;
}
#picture-dialog .modal-body h3 {
    font-size: 20px;
    line-height: 24px;
    margin-bottom: 10px;
}
#picture-dialog .well {
    padding: 10px;
}
#picture-dialog .tab {
    display: none;
    min-height: 300px;
}
#picture-dialog .tab.active {
    display: block;
}
#picture-dialog .actions {
    border-top: 1px solid #ccc;
    margin-top: 15px;
    padding-top: 15px;
    height: 28px;
    display: block;
}
#tab-picture-rotate .canvas {
    width: 200px;
    height: 200px;
    border: 1px solid #ddd;
    background: #efefef;
    display: table-cell;
    vertical-align: middle;
    text-align: center;
    margin: 0 10px 10px 0;
    overflow: hidden;
}
#tab-picture-rotate .rotate-options {
    margin-left: 15px;
}
#tab-picture-crop .canvas {
    width: 380px;
    height: 380px;
    border: 1px solid #ddd;
    background: #efefef;
    display: table-cell;
    vertical-align: middle;
    text-align: center;
}
#tab-picture-crop .canvas img {
    max-width: 380px;
    max-height: 380px;
}
#tab-picture-crop .btn-group {
    margin-top: 15px;
}
#tab-picture-crop .cropper {
    position: absolute;
}
#tab-picture-crop .cropper-border {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    border: 1px dashed #333;
}
#tab-picture-crop .cropper-border-rounded {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    border: 1px dashed #333;
    border-radius: 100%;
}
#tab-picture-filter .filter-cell {
    height: 120px;
    width: 120px;
    float: left;
    margin: 5px;
    box-sizing: border-box;
    -moz-box-sizing: border-box;
    -webkit-box-sizing: border-box;
    border: 2px solid #ddd;
}
#tab-picture-filter .filter-cell.active {
    border-color: #57f;
}
#tab-picture-filter .canvas {
    width: 400px;
    height: 400px;
    position: relative;
}
#tab-picture-filter .canvas .inner {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1000;
}
#tab-picture-filter .message {
    display: none;
}
#tab-picture-filter .message.active {
    display: block;
    position: absolute;
    top: 50%;
    left: 50%;
    height: 1.5em;
    width: 100px;
    margin-left: -50px;
    text-align: center;
}

/* Card list */
#card-filter {
    margin-top: 20px;
    font-size: 20px;
    line-height: 20px;
}
#card-filter a {
    display: inline-block;
}
#card-filter a.active {
    color: #333;
    font-weight: bold;
}
#card-preview {
    display: table;
    width: 100%;
    height: 320px;
    margin-bottom: 20px;
}
#card-preview .inner {
    display: table-cell;
    height: 300px;
    width: 300px;
    vertical-align: middle;
    text-align: center;
}
#card-preview img {
    display: inline;
    max-width: 95%;
}
#card-preview .loading,
#modal-preview .loading {
    display: block;
    position: absolute;
    top: 50%;
    left: 0;
    font-size: 14px;
    line-height: 16px;
    width:100%;
    height: 16px;
    margin-top:-8px;
    color: #0088CC;
    text-align: center;
}
#card-preview .loading img,
#modal-preview .loading img {
    max-width: none;
    display: inline-block;
    margin-right: 5px;
    width: 16px;
    height: 16px;
    vertical-align: text-top;
}

/* Cardmaker's Cards list filters */
#form-filter .search-wrapper {
    position: relative;
    display: inline-block;
}
#form-filter .search-wrapper i {
    position: absolute;
    top: 7px;
    right: 7px;
    display: none;
}

/* Image frame */
.frame {
    display: table;
    position: relative;    
}
.frame .inner {
    display: table-cell;
    vertical-align: middle;
    text-align: center;
    height: 100%;
    width: 100%;
}
.frame .inner img {
    display: inline;
    max-width: 95%;
    box-shadow: 0px 0px 6px #333;
}
.frame-small { width: 40px; height: 40px; }
.frame-medium { width: 120px; height: 120px; }
.frame-large { width: 200px; height: 200px; }
.frame-xlarge { width: 300px; height: 300px; }
.frame-xlarge-double { width: 600px; height: 300px; }
.frame-small img { max-height: 36px; max-width: 36px; }
.frame-medium img { max-height: 114px; max-width: 114px; }
.frame-large img { max-height: 192px; max-width: 192px; }
.frame-xlarge img { max-height: 290px; max-width: 290px; }

/* Frame in table */
td .frame {
    float: left;
    margin-right: 2px;
}

/* Modal preview */
#modal-preview {
    width: 660px;
    margin-left: -330px;
}
#modal-preview .inner {
    width: 290px;
    height: 290px;
}

/* Order details */
#order-details hr {
    clear: both;
    width: 100%;
    margin: 10px 0;
}

/* Popover */
.tooltip {
    z-index: 2000;
}

/** Card list */
tr.active td {
  background-color: #def;
}
.pagination {
    margin: 0 0 18px 0;
}
#cards-table {
    margin-bottom: 0;
}
#cards-table td {
    -ms-word-break: break-all;
    word-break: break-all;
}
#cards-table td.actions {
    -ms-word-break: normal;
    word-break: normal;
}
#cards-table tbody tr:first-child td {
    border-top: none;
}
#cards-table-wrapper {
    margin-top: -28px;
    overflow-y: scroll;
    padding-right: 10px;
    margin-bottom: 20px;
    height: 300px;
}
#cards-table-thead {
    background: #efefef;
    z-index: 20;
    position: relative;
    margin: 0;
}
#cards-table-thead th {
    white-space: nowrap;
}
#cards-table .frame {
    cursor: pointer;
}
.table input[type="checkbox"] {
    margin-top: 0;
}

/* Date & Time */
.datetime {
    display: block;
}
.datetime span {
    font-size: 12px;
    line-height: 14px;
    display: inline-block;
}
.datetime {
    color: #555; 
}
.datetime.modified {
    color: #888;
}

/* Date picker */
.ui-datepicker .ui-datepicker-title select {
    height: auto;
    line-height: 1em;
    padding: 2px 4px;
    font-size: 0.9em;
    width: auto;
}

/* Import Tool */
#import-tool .step form {
    min-height: 250px;
}
#import-tool .actions {
    padding-left: 0;
    padding-top: 10px;
    margin-top: 10px;
    border-top: 1px solid #fff;
    height: 30px;
}
#import-tool h2 {
    color: #555;
    font-size: 24px;
    line-height: 28px;
    padding-bottom: 10px;
    margin-bottom: 10px;
    border-bottom: 1px solid #fff;
}
#import-tool .step .required {
    font-weight: bold;
}
#import-tool .table-code {
    margin: 0;
}
#import-tool .table-code td {
    font-size: 11px;
    font-family: "Courier New", Courier, monospace;
    white-space: nowrap;
}
#import-tool .table-code .title td {
    font-weight: bold;
    border-bottom: 1px solid #888;
}
#import-tool .scrollable-horizontal {
    width: 100%;
    overflow-x: scroll;
    margin: 10px 0;
}

@media (max-width: 979px) {
    body {
        padding-top: 0;
    }
}