@charset "utf-8";

html {
    font-size: 62.5%;
    -webkit-text-size-adjust: none;
}

button, input, optgroup, select, textarea {
    font-family: 'Varela Round', 'Noto Sans Japanese', sans-serif;
}

body {
    background-color: #fff;
    font-family: 'Varela Round', 'Noto Sans Japanese', sans-serif;
    font-weight: 300;
    color: #1b1b1b;
    line-height: 1.7;
}

ul, li { margin:0; padding:0; list-style:none; }

strong { font-weight:bold !important; }

/* スマートフォンに適用するスタイルを書く */

/**
 * 共通
 */
header {
    position: relative;
    padding: 10px 0;
    background-color: #a7c6da;
    background-image: -webkit-linear-gradient(top, #c7dae7, #a7c6da);
    background-image: -ms-linear-gradient(top, #c7dae7, #a7c6da);
    background-image: -o-linear-gradient(top, #c7dae7, #a7c6da);
    background-image: linear-gradient(top, #c7dae7, #a7c6da);
    background-image: -webkit-linear-gradient(top, #f90, #fa3);
    color: #fff;
    text-align: center;
    text-shadow: 0 -1px 1px rgba(0, 0, 0, 0.4), 0 1px 1px rgba(255, 255, 255, 0.5);
}

.spmenu_btn {
    display: block;
    position: absolute;
    top: 14px;
    right: 15px;
    width: 30px;
    height: 22px;
    background-color: #fff;
    border-top: 10px solid #f90;
    border-bottom: 10px solid #ff9f11;
    box-sizing: border-box;
    transition: all 0.3s;
}
.spmenu_btn:before {
    content: '';
    position: absolute;
    top: -9px;
    right: 0;
    width: 30px;
    height: 2px;
    background-color: #fff;
    transition: all 0.3s;
}
.spmenu_btn:after {
    content: '';
    position: absolute;
    bottom: -9px;
    right:0;
    width: 30px;
    height: 2px;
    background-color: #fff;
    transition: all 0.3s;
}
.spmenu_btn.active {
    background-color: #ff9e0e;
}
.spmenu_btn.active:before {
    top: 0;
    right: 0;
    transform: rotate(-135deg);
}
.spmenu_btn.active:after {
    bottom: 0;
    right: 0;
    transform: rotate(135deg);
}

.spmenu {
    display: none;
    position: absolute;
    top: 48px;
    right: 0;
    z-index: 1;
    width: 33%;
    background-color: #c7dae7;
    background-image: -webkit-linear-gradient(top, #a7c6da, #c7dae7);
    background-image: -ms-linear-gradient(top, #a7c6da, #c7dae7);
    background-image: -o-linear-gradient(top, #a7c6da, #c7dae7);
    background-image: linear-gradient(top, #a7c6da, #c7dae7);
    background-image: -webkit-linear-gradient(top, #666, #333);
}

nav {
    display: block;
    margin: 0 auto;
    width: 100%;
}
nav li a,
nav li p {
    display: block;
    position: relative;
    margin: 0;
    padding: 15px;
    width: 100%;
    font-size: 1.4rem;
    font-weight: normal;
    color: #fff;
    box-sizing: border-box;
    border-bottom: 1px solid #999;
    text-decoration: none;
    text-shadow: none;
}
nav li p { color:#666; }

h1 {
    margin: 0;
    font-size: 20px;
    line-height: 1.4;
    letter-spacing: 2px;
}

footer {
    position: absolute;
    bottom: 0;
    padding: 4px 0;
    width: 100%;
    height: 17px;
    background-color: #ff6d00;
    color: #fff;
    text-align: center;
}
footer p {
    margin: 0;
    font-size: 10px;
    font-size: 1.0rem;
}

.wrapper {
    min-height: 100vh;
    position: relative;
    padding-bottom: 25px;
    box-sizing: border-box;
}

/**
 * 支払日
 * 費目
 * 支払額
 */
.calendar ,
.item,
.cost,
.total {
    margin: 2.5vh auto;
    padding: 1.5vh 3vw 0;
    width: 100%;
    height: auto;
    background-color: #fff;
    box-sizing: border-box;
}

.calendar h2,
.item h2,
.cost h2,
.total h2 {
    margin: 0;
    padding: 3px;
    border-bottom: 1px solid #999;
    border-left: 6px solid #cacaca;
    font-size: 2.2rem;
    color: #333;
    text-align: left;
    line-height: 1;
}

.calendar div,
.item div,
.cost div {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    margin-top: 1vh;
}
.calendar div {
    position: relative;
}
.item div {
    justify-content: space-between;
}

.calendar div p,
.item div p,
.cost div p {
    margin: 0;
    width: 14%;
    font-size: 16px;
    font-size: 1.6rem;
    text-align: center;
    line-height: 1;
}
.calendar div.select_year,
.calendar div.select_month {
    position: absolute;
    z-index: 999;
    display: none;
    background-color: #fff;
    border: 1px solid #000;
    box-sizing: border-box;
}
.calendar div.select_year p,
.calendar div.select_month p {
    padding: 6px 4px;
    width: 100%;
    text-align: left;
    box-sizing: border-box;
}
.calendar div.select_month p {
    text-align: right;
}
.calendar div h3 {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding: 3px 0;
    width: 100%;
    font-size: 1.8rem;
    text-align: center;
    line-height: 1.6;
}
.calendar h3 p {
    display: inline-flex;
    align-items: center;
    width: auto;
}
.calendar h3 p:first-of-type {
    margin-right: 1em;
}

.calendar div svg.chevron-down {
    width: 22px;
    height: 22px;
}
.calendar div p.prev_month,
.calendar div p.next_month {
    position: absolute;
    top: 0;
    padding: 6px 3px;
    width: 5%;
    border: 1px solid #aaa;
    border-radius: 3px;
    background-image: -webkit-linear-gradient(top, #fff, #eee); /* For Chrome and Safari */
    background-image: linear-gradient(top, #fff, #eee); /* Standard syntax; must be last */
    color: #333;
    /*text-shadow: .5px .5px 1px #eee, 0 0 #000;*/
    cursor: pointer;
}
.calendar div p.prev_month {
    left: 0;
}
.calendar div p.next_month {
    right: 0;
}
.calendar div p input[type=radio],
.item div p input[type=radio] {
    display: none;
}
.calendar div p input[type=radio]:checked + label,
.item div p input[type=radio]:checked + label {
    background-color: #31a9ee;
    color: #fff;
}
.calendar p .week_name,
.calendar p .label ,
.item p .label {
    display: block;
    margin: 0;
    padding: 1.5vh 0;
    color: #333;
}
.calendar p .label,
.item p .label {
    border-radius: 5px;
    color: #666;
    cursor: pointer;
}
.red, .calendar p .sunday { color:#c00; }
.blue, .calendar p .saturday { color:#00c; }

.calendar p label.is_cost {
    background-color: #ffc;
}

/**
 * 登録済コスト
 */
#display_costs {
    margin: 0;
    padding: 0 3vw;
}
#display_costs dl {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    margin: 10px 0 0;
    font-size: 20px;
    font-size: 2rem;
}

#display_costs dt {
    position: relative;
    margin: 0 0 6px;
    padding: 0 4px;
    width: 10rem;
    background-color: #eee;
    border: 1px solid #ccc;
    text-align: right;
    border-radius: 3px;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    box-sizing: border-box;
}
#display_costs dd {
    display: flex;
    /*flex-wrap: wrap;*/
    align-items: center;
    margin: 0 0 6px;
    padding: 0 4px;
    width: calc(100% - 10rem - 8px);
    border: 1px solid #ccc;
    border-left: none;
    border-radius: 3px;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    box-sizing: border-box;
}
#display_costs dd:last-of-type { background-color:#eee; }
#display_costs dd input,
#display_costs dd p {
    padding: 0;
    width: 8rem;
    border: none;
    text-align: right;
}
#display_costs dd input {
    outline: none;
}
#display_costs dd span.yoy {
    font-size: 1.4rem;
    /*width: 100%;*/
}
#display_costs .control-icons {
    margin: 0 0 0 auto;
}
#display_costs svg.editable,
#display_costs svg.check,
#display_costs svg.trash {
    width: 30px;
    height: 30px;
}
#display_costs svg.check {
    display: none;
    color: #393;
}
#display_costs svg.trash {
    position: absolute;
    top: 0;
    left: 0;
    display: none;
    width: 20px;
    height: 20px;
    color: #c00;
}
#display_costs p.nodata {
    margin-top: 1vh;
    width: 100%;
    font-size: 14px;
    font-size: 1.4rem;
    text-align: center;
}

/**
 * 費目
 */
.item {}
.item div p {
    margin-bottom: 1rem;
    /*margin-right: 1%;*/
    width: 32%;
    background-color: #e5e5e5;
    border-radius: 5px;
}
.item div p:last-of-type { margin-right:0; }
.item p .label { padding:2.6vh 0; }

/**
 * 支払額
 */
 .cost {}
 .cost div {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    align-items: strech;
    width: 100%;
}
 .cost div input[name="cost"] {
    position: relative;
    flex: 1 1 auto;
    margin: 0;
    padding: 1vh 2vw;
    width: 1%;
    min-width: 0;
    border: 1px solid #ccc;
    font-family: 'Varela Round', 'Noto Sans Japanese', sans-serif;
    font-size: 16px;
    font-size: 2rem;
    text-align: center;
    border-radius: 5px;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    box-shadow: 0 1px 1px #ccc inset, 0 1px 0 #fff;
 }
.cost div input[name="cost"]:focus {
    background-color: #fff;
    border-color: #86b7fe;
    outline: none;
    box-shadow: 0 0 0 0.25rem rgb(13 110 253 / 25%);
}
.cost div span.cost_unit {
    margin: 0;
    margin-left: -1px;
    padding: 1vh 8vw;
    background-color: #e9ecef;
    border: 1px solid #ced4da;
    font-size: 16px;
    font-size: 1.6rem;
    text-align: center;
    border-radius: 5px;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}


/**
 * 集計
 */
 .total {
    margin-top: 0;
 }
 .prev_next {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    padding-bottom: 1.5vh;
 }
.prev_next a.prev_year,
.prev_next a.next_year {
    display: block;
    padding: 3px;
    border: 1px solid #aaa;
    border-radius: 3px;
    background-image: -webkit-linear-gradient(top, #fff, #eee); /* For Chrome and Safari */
    background-image: linear-gradient(top, #fff, #eee); /* Standard syntax; must be last */
    color: #333;
    font-size: 14px;
    font-size: 1.4rem;
    text-decoration: none;
}
 .total_month {
    margin-top: 1em;
    width: 100%;
    box-sizing: border-box;
}
.total_month li:first-of-type {
    position: relative;
    padding: 3px 0 3px 10px;
    background-color: #e5e5e5;
    border: 1px solid #999;
    border-radius: 4px;
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    font-size: 16px;
    font-size: 1.6rem;
}
#date_total svg.plus,
#date_total svg.minus {
    position: absolute;
    top: calc(50% - 12px);
    right: 10px;
    margin: 0 0 0 auto;
    width: 22px;
    height: 22px;
}
#date_total svg.minus {
    display: none;
}
#date_total p.nodata {
    margin-top: 5vh;
    width: 100%;
    font-size: 14px;
    font-size: 1.4rem;
    text-align: center;
}
.total_month li:last-of-type {
    padding: 3px 10px 3px 0;
    background-color: #e5e5e5;
    border: 1px solid #999;
    border-top: none;
    border-radius: 4px;
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    font-size: 16px;
    font-size: 1.6rem;
    text-align: right;
}
.total_month li dl {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    margin: 0;
    border: 1px solid #999;
    border-top: none;
    border-bottom-style: dashed;
    font-size: 16px;
    font-size: 1.6rem;
}
.total_month li dl:last-of-type {
    border-bottom-style: solid;
}
.total_month li dt {
    margin: 0;
    padding: 3px;
    width: 40%;
    box-sizing: border-box;
    text-align: right;
}
.total_month li dd {
    margin: 0;
    padding: 3px 10px 3px 0;
    width: 60%;
    box-sizing: border-box;
    text-align: right;
}


/**
 * ボタン
 */
#btn_login,
input[name="register"] {
    display: block;
    margin: 0 auto 20px;
    padding: 0;
    width: 44vw;
    height: 40px;
    background-color: #cde7be;
    border: 1px solid #b5d5a2;
    border-radius: 3px;
    font-family: 'Varela Round', 'Noto Sans Japanese', sans-serif;
    font-size: 1.6rem;
    font-size: 16px;
    color: #6a825c;
    cursor: pointer;
}
input[name="register"] { margin-top:50px; }

input[name="register"]:not(.disabled):hover,
input[name="register"]:not(.disabled):focus { background-color:#daedcf; }

input[name="register"].disabled {
    background-color: #ccc;
    border-color: #999;
    color: #999;
}

/**
 * login only.
 */
fieldset {
    margin: 0;
    padding: 0 20px;
    border: 0;
}

#inputs input {
    margin: 0 auto 10px;
    padding: 15px 15px 15px 30px;
    width: calc(100% - 45px);
    background: #f1f1f1 url(../images/login-sprite.png) no-repeat;
    border: 1px solid #ccc;
    border-radius: 5px;
    -webkit-box-shadow: 0 1px 1px #ccc inset, 0 1px 0 #fff;
    box-shadow: 0 1px 1px #ccc inset, 0 1px 0 #fff;
    font-family: "メイリオ", "Meiryo", "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", "ＭＳ Ｐゴシック", "MS PGothic", sans-serif;
    font-size: 14px;
    font-size: 1.4rem;
}
#inputs input:focus {
    background-color: #fff;
    border-color: #e8c291;
    outline: none;
    -webkit-box-shadow: 0 0 0 1px #e8c291 inset;
    box-shadow: 0 0 0 1px #e8c291 inset;
}

#login {
    position: relative;
    top: 10px;
    z-index: 0;
    margin: 0 auto 30px;
    padding: 6% 0;
    width: 90%;
    background-color: #fff; /* fallback color if gradients are not supported */
    background-image: -webkit-linear-gradient(top, #fff, #eee); /* For Chrome and Safari */
    background-image: -ms-linear-gradient(top, #fff, #eee); /* For pre-releases of IE 10*/
    background-image: -o-linear-gradient(top, #fff, #eee); /* For old Opera (11.1 to 12.0) */
    background-image: linear-gradient(top, #fff, #eee); /* Standard syntax; must be last */
    border-radius: 3px;
    -webkit-box-shadow: 0 0 2px rgba(0, 0, 0, 0.2),
                        0 1px 1px rgba(0, 0, 0, .2),
                        0 3px 0 #fff,
                        0 4px 0 rgba(0, 0, 0, .2),
                        0 6px 0 #fff,
                        0 7px 0 rgba(0, 0, 0, .2);
    box-shadow: 0 0 2px rgba(0, 0, 0, 0.2),
                0 1px 1px rgba(0, 0, 0, .2),
                0 3px 0 #fff,
                0 4px 0 rgba(0, 0, 0, .2),
                0 6px 0 #fff,
                0 7px 0 rgba(0, 0, 0, .2);
}
#login:before {
    content: '';
    position: absolute;
    z-index: -1;
    border: 1px dashed #ccc;
    top: 5px;
    bottom: 5px;
    left: 5px;
    right: 5px;
    -webkit-box-shadow: 0 0 0 1px #fff;
    box-shadow: 0 0 0 1px #fff;
}
#login h2 {
    position: relative;
    margin: 0 0 30px 0;
    font-size: 22px;
    color: #666;
    line-height: 1;
    text-shadow: 0 1px 0 rgba(255, 255, 255, .7), 0px 2px 0 rgba(0, 0, 0, .5);
    text-transform: uppercase;
    text-align: center;
    letter-spacing: 4px;
}
#login h2:after,
#login h2:before {
    position: absolute;
    top: 12px;
    width: 80px;
    height: 1px;
    background-color: #777;
    content: '';
}
#login h2:after {
    right: 10px;
    background-image: -webkit-linear-gradient(left, #777, #fff);
    background-image: -ms-linear-gradient(left, #777, #fff);
    background-image: -o-linear-gradient(left, #777, #fff);
    background-image: linear-gradient(left, #777, #fff);
}
#login h2:before {
    left: 10px;
    background-image: -webkit-linear-gradient(right, #777, #fff);
    background-image: -ms-linear-gradient(right, #777, #fff);
    background-image: -o-linear-gradient(right, #777, #fff);
    background-image: linear-gradient(right, #777, #fff);
}

#username { background-position:5px -2px !important; }
#password { background-position:5px -52px !important; }

#actions { margin:1.5vh 0 0 0; }

@keyframes dots-loader {
  0% {
    box-shadow: #f86 -11px -11px 0 7px, #fc6 11px -11px 0 7px, #6d7 11px 11px 0 7px, #4ae -11px 11px 0 7px;
  }
  8.33% {
    box-shadow: #f86 11px -11px 0 7px, #fc6 11px -11px 0 7px, #6d7 11px 11px 0 7px, #4ae -11px 11px 0 7px;
  }
  16.67% {
    box-shadow: #f86 11px 11px 0 7px, #fc6 11px 11px 0 7px, #6d7 11px 11px 0 7px, #4ae -11px 11px 0 7px;
  }
  25% {
    box-shadow: #f86 -11px 11px 0 7px, #fc6 -11px 11px 0 7px, #6d7 -11px 11px 0 7px, #4ae -11px 11px 0 7px;
  }
  33.33% {
    box-shadow: #f86 -11px -11px 0 7px, #fc6 -11px 11px 0 7px, #6d7 -11px -11px 0 7px, #4ae -11px -11px 0 7px;
  }
  41.67% {
    box-shadow: #f86 11px -11px 0 7px, #fc6 -11px 11px 0 7px, #6d7 -11px -11px 0 7px, #4ae 11px -11px 0 7px;
  }
  50% {
    box-shadow: #f86 11px 11px 0 7px, #fc6 -11px 11px 0 7px, #6d7 -11px -11px 0 7px, #4ae 11px -11px 0 7px;
  }
  58.33% {
    box-shadow: #f86 -11px 11px 0 7px, #fc6 -11px 11px 0 7px, #6d7 -11px -11px 0 7px, #4ae 11px -11px 0 7px;
  }
  66.67% {
    box-shadow: #f86 -11px -11px 0 7px, #fc6 -11px -11px 0 7px, #6d7 -11px -11px 0 7px, #4ae 11px -11px 0 7px;
  }
  75% {
    box-shadow: #f86 11px -11px 0 7px, #fc6 11px -11px 0 7px, #6d7 11px -11px 0 7px, #4ae 11px -11px 0 7px;
  }
  83.33% {
    box-shadow: #f86 11px 11px 0 7px, #fc6 11px -11px 0 7px, #6d7 11px 11px 0 7px, #4ae 11px 11px 0 7px;
  }
  91.67% {
    box-shadow: #f86 -11px 11px 0 7px, #fc6 11px -11px 0 7px, #6d7 11px 11px 0 7px, #4ae -11px 11px 0 7px;
  }
  100% {
    box-shadow: #f86 -11px -11px 0 7px, #fc6 11px -11px 0 7px, #6d7 11px 11px 0 7px, #4ae -11px 11px 0 7px;
  }
}

/* :not(:required) hides this rule from IE9 and below */
.dots-loader:not(:required) {
  overflow: hidden;
  position: relative;
  text-indent: -9999px;
  display: inline-block;
  width: 6px;
  height: 6px;
  background: transparent;
  border-radius: 100%;
  box-shadow: #f86 -11px -11px 0 7px, #fc6 11px -11px 0 7px, #6d7 11px 11px 0 7px, #4ae -11px 11px 0 7px;
  animation: dots-loader 5s infinite ease-in-out;
  transform-origin: 50% 50%;
  margin: 0 auto;
  top: 20px;
}