@import "mixins.scss"; // // Android theme // The visual and interaction styles for Android // // -------------------------------------------------- @import url(http://fonts.googleapis.com/css?family=Roboto:400,700,500); // Variables // -------------------------------------------------- // Type (Change to Roboto) $font-family-default: 'Roboto', sans-serif; $font-size-default: 18px; $font-weight: 500; $font-weight-light: 400; $line-height-default: 22px; // Colors // Main theme colors $primary-color: #33b5e5; $chrome-color: #dddddd; $text-color: #222; // Action colors $default-color: #999; $positive-color: #99cc00; $negative-color: #ff4444; // Bars $bar-base-height: 50px; $bar-tab-height: 50px; // Borders $border-default: 1px solid #b1b1b1; $border-radius: 2px; // Base // -------------------------------------------------- body { font-family: $font-family-default; font-size: $font-size-default; line-height: $line-height-default; color: $text-color; } .content { background-color: #f2f2f2; } // Pad top/bottom of content so it doesn't hide behind .bar-title and .bar-tab. // Note: For these to work, content must come after both bars in the markup .bar-nav ~ .content { padding-top: $bar-base-height; } .bar-tab ~ .content { padding-bottom: $bar-tab-height; } .bar-header-secondary ~ .content { padding-top: $bar-base-height*2; } // Bars // -------------------------------------------------- .bar { height: $bar-base-height; background-color: $chrome-color; border-bottom: $border-default; box-shadow: inset 0 -2px 0 #d2d2d2, 0 3px 3px rgba(0,0,0,.07); // Modifier class to dock any bar below .bar-nav &.bar-header-secondary { top: $bar-base-height + 1; } } .bar-tab { height: $bar-tab-height; border-top: $border-default; border-bottom: 0; box-shadow: inset 0 2px 0 #d2d2d2, 0 -3px 3px rgba(0,0,0,.07); .tab-item .icon { margin-top: 0; } } // Left aligned text in the .bar-nav .title { position: static; padding-left: 15px; font-size: $font-size-default; line-height: $bar-base-height; text-align: left; } // // Cards // -------------------------------------------------- .card { border-color: #d9d9d9; border-radius: $border-radius; } // `bar-nav` in popovers .popover { .bar { border-radius: 0; } .bar ~ .table-view { padding-top: $bar-base-height; } } // Table views // -------------------------------------------------- .table-view { .table-view-cell { border-bottom: 1px solid #d9d9d9; // Remove the border from the last table view item &:last-child { background-image: none; } > a:not(.btn):active { background-color: $primary-color; .icon { color: #fff; } } } // Table view dividers .table-view-divider { padding-top: 25px; font-size: 12px; font-weight: bold; text-transform: uppercase; border-top: 0; border-bottom: 2px solid #a9a9a9; background-color: transparent; } } .popover .table-view { border-radius: 12px; } // Forms // -------------------------------------------------- select, textarea, input[type="text"], input[type="search"], input[type="password"], input[type="datetime"], input[type="datetime-local"], input[type="date"], input[type="month"], input[type="time"], input[type="week"], input[type="number"], input[type="email"], input[type="url"], input[type="tel"], input[type="color"], .input-group { height: 40px; padding: 10px 15px; border: 1px solid rgba(0, 0, 0, .2); box-shadow: 0 1px 1px rgba(0,0,0,.1); } input[type="search"] { border-radius: $border-radius; } select, textarea, .input-group { height: auto; } // Input groups (cluster multiple inputs together into a single group) // ------------------------------------------------------------------- .input-group { padding: 0; border: 0; } .input-group input { border: 0; border-bottom: 1px solid #d9d9d9; box-shadow: none; } // Remove bottom border on last input to avoid double bottom border .input-group input:last-child { background-image: none; } // Input groups with labels // -------------------------------------------------- // To use labels with input groups, wrap a label and an input in an .input-row .input-row { border-bottom: 1px solid #d9d9d9; } // Remove bottom border on last input-row to avoid double bottom border .input-row label + input { background-image: none; border-bottom: 0; } // Buttons // -------------------------------------------------- .btn { color: $text-color; background-color: #cecece; border: 0; border-radius: $border-radius; box-shadow: inset 0 -1px 0 rgba(0,0,0,.2), inset 0 1px 0 rgba(255,255,255,.2), 0 1px 1px rgba(0,0,0,.25); // Active & filled button styles &:active, &.active { color: $text-color; border: 0; background-color: $default-color; box-shadow: inset 0 -1px 0 rgba(0,0,0,.2), inset 0 1px 0 rgba(255,255,255,.2); } } .bar { .btn { padding-top: 9px; padding-bottom: 9px; } .btn-link { padding: 0; color: $primary-color; font-size: $font-size-default; line-height: $bar-base-height; &:active, &.active { color: darken($primary-color, 10%); } } } // Other button types // -------------------------------------------------- // Primary button (Default color is blue) .btn-primary { color: #fff; border: 0; background-color: $primary-color; &:active, &.active { color: #fff; border: 0; background-color: darken($primary-color, 10%); } } // Positive button (Default color is green) .btn-positive { color: #fff; border: 0; background-color: $positive-color; &:active, &.active { color: #fff; border: 0; background-color: darken($positive-color, 10%); } } // Negative button (Default color is red) .btn-negative { color: #fff; border: 0; background-color: $negative-color; &:active, &.active { color: #fff; border: 0; background-color: darken($negative-color, 10%); } } // Outlined buttons .btn-outlined { border: 1px solid $default-color; background-color: transparent; box-shadow: none; &.btn-primary { border: 1px solid $primary-color; color: $primary-color; &:active { border: 1px solid $primary-color; background-color: $primary-color; } } &.btn-positive { border: 1px solid $positive-color; color: $positive-color; &:active { border: 1px solid $positive-color; background-color: $positive-color; } } &.btn-negative { border: 1px solid $negative-color; color: $negative-color; &:active { border: 1px solid $negative-color; background-color: $negative-color; } } // Active states &:active { border: 1px solid $default-color; background-color: $default-color; box-shadow: none; } &.btn-primary:active, &.btn-positive:active, &.btn-negative:active { color: #fff; box-shadow: none; } } // Link button (Buttons that look like links) .btn-link { color: $primary-color; background-color: transparent; border: none; box-shadow: none; &:active, &.active { color: darken($primary-color, 10%); background-color: transparent; box-shadow: none; } } // Buttons in nav bars // -------------------------------------------------- .bar-nav { .btn-link { color: $primary-color; &:active { color: $primary-color; opacity: .6; } } } // // Badges // -------------------------------------------------- .badge { &.badge-inverted { color: $default-color; background-color: transparent; } } // Badge modifiers // -------------------------------------------------- // Main badge .badge-primary { color: #fff; background-color: $primary-color; &.badge-inverted { color: $primary-color; background-color: transparent; } } // Positive badge .badge-positive { color: #fff; background-color: $positive-color; &.badge-inverted { color: $positive-color; background-color: transparent; } } // Negative badge .badge-negative { color: #fff; background-color: $negative-color; &.badge-inverted { color: $negative-color; background-color: transparent; } } // Badges in buttons .btn { .badge { background-color: rgba(0,0,0,.15); &.badge-inverted { background-color: transparent; } } // Active states &:active .badge { color: #fff; } } // // Segmented controllers // -------------------------------------------------- .segmented-control { background-color: transparent; border: 1px solid $primary-color; border-radius: 3px; li { border-left: 1px solid $primary-color; // Link that fills each section > a { padding-top: 9px; padding-bottom: 10px; color: $primary-color; } &.active { background-color: $primary-color; } } } // // Popovers // -------------------------------------------------- .popover { top: 100px; border: 1px solid #9b9b9b; border-radius: 0; box-shadow: 0 0 3px rgba(0,0,0,.2); @include transition(-webkit-transform 0.2s ease-in-out, transform 0.2s ease-in-out, opacity 0.2s ease-in-out); &:before { display: none; } } // // Toggles styles // -------------------------------------------------- .toggle { width: 104px; height: 28px; border: 2px solid #d7d7d7; border-radius: 0; background-color: #d7d7d7; // Sliding handle .toggle-handle { top: 0; left: 0; width: 50px; height: 24px; border: 1px solid #b5b5b5; border-radius: 0; background-color: #bebebe; box-shadow: inset 0 1px 0 rgba(255,255,255,.3), inset 0 -1px 0 rgba(0,0,0,.1); } &:before { top: 1px; right: auto; left: 11px; z-index: 3; color: #fff; } // Active state for toggle &.active { background-color: #d7d7d7; .toggle-handle { margin-right: 2px; background-color: $primary-color; border-color: $primary-color; @include transform(translate3d(50px,0,0)); } &:before { left: auto; right: 14px; color: #fff; content: "On"; } } } // Ratchicons in nav bars .bar .icon { margin-top: 13px; }