// _main.scss
#app {
@include grid(null, null, 28px);
margin: 65px 0;
.vending-machine {
grid-column: 1 / 2;
padding: 30px 30px 30px 27px;
background-color: $white;
}
.my-page {
@include grid(null, null, 20px);
grid-column: 2 / 3;
width: 369px;
}
}
// ul.list-items-cart
.list-items-cart {
@include itemStyle($border-main, null, $sub-color);
overflow-y: scroll;
padding: 12px 16px 12px 12px;
&::-webkit-scrollbar {
width: 4px;
}
&::-webkit-scrollbar-track {
background: transparent;
}
&::-webkit-scrollbar-thumb {
@include itemStyle(null, $border-r-5, rgba(255, 255, 255, 0.8));
}
.item-cart {
@include itemStyle(null, $border-r-5, $white);
overflow: hidden;
padding: 8px 8px 8px 10px;
}
.item-cart + .item-cart {
margin-top: 6px;
}
.img-item {
width: 18px;
height: 33px;
}
.tit-item {
@include fontStyle(null, $font-9, null, 33px);
margin-left: 10px;
}
.num-counter {
@include itemStyle($border-main, $border-r-5);
float: right;
width: 31px;
height: 31px;
text-align: center;
line-height: 30px;
}
}
// section.vending-machine
.vending-machine {
.list-items {
@include grid(repeat(3, 96px), repeat(2, minmax(136px, auto)), 12px);
li {
@include itemStyle(null, $border-r-10, null, $shadow-25);
&.selected {
position: relative;
}
&.selected::after {
@include itemAfter(-3px, -3px, -3px, -3px);
border: 3px solid $main-color;
}
&.sold-out {
position: relative;
&::after {
@include itemAfter;
background: url("../img/Sold-out.png") no-repeat center center
rgba(0, 0, 0, 0.8);
background-size: 70%;
}
}
}
.btn-item {
@include flex(column, center, space-between);
@include itemStyle(null, $border-r-10, $white);
width: 100%;
height: 100%;
padding: 10px 0;
.img-item {
width: 36px;
height: 65px;
}
.tit-item {
@include fontStyle(null, $font-9, $font-w-500);
}
.txt-item {
@include itemStyle(null, 50px, $main-color);
@include fontStyle($white, $font-12);
width: 70px;
padding: 5px 0;
}
}
}
}
.vending-machine {
.cont-mycart {
@include grid(204px 96px, 33px 33px 106px, 12px);
margin-top: 20px;
.cart-mycart__col-left {
@include itemStyle(null, $border-r-5);
@include fontStyle(null, $font-14, null, 20px);
padding: 6px 10px 7px;
}
.info-balance {
overflow: hidden;
background-color: $sub-color;
.txt-balance {
float: right;
}
}
.inp-insert {
border: $border-main;
background: $white;
&::placeholder {
@include fontStyle(#bdbdbd, $font-13, null);
}
}
.cart-mycart__col-right {
@include itemStyle(null, $border-r-5, $white, $shadow-25);
@include fontStyle(null, $font-13);
padding: 6px 0 7px;
}
.btn-get {
@include itemStyle(null, null, $main-color, $shadow-50);
@include fontStyle($white, null, $font-w-700);
}
}
}
// section.my-page
.my-page {
.cont-mymoney {
padding: 9px 27px;
background-color: $white;
.info-mymoney {
@include itemStyle(null, $border-r-5, $sub-color);
@include fontStyle(null, $font-14, null, 20px);
overflow: hidden;
padding: 6px 10px;
}
.txt-mymoney {
float: right;
font-weight: $font-w-700;
}
}
.cont-myitems {
overflow: hidden;
padding: 25px 27px;
background-color: $white;
text-align: center;
.tit-myitems {
@include fontStyle(null, $font-14, null, 20px);
}
.list-items-cart {
@include itemStyle(null, $border-r-5);
height: 378px;
margin: 13px 0 6px;
text-align: left;
}
}
.tit-total {
@include fontStyle(null, $font-12, null, 17px);
float: right;
}
}
@media screen and (max-width: $media-w-md) {
#app {
.vending-machine {
grid-row: 1 / 2;
}
.my-page {
grid-column: 1 / 2;
grid-row: 2 / 3;
}
}
}
@media screen and (max-width: $media-w-sm) {
#app {
gap: 0;
margin: 16px 0 0;
.vending-machine {
grid-row: 1 / 2;
padding-bottom: 20px;
}
.my-page {
row-gap: 0;
grid-column: 1 / 2;
grid-row: 2 / 3;
.cont-mymoney {
padding: 0 27px;
}
.cont-myitems {
padding: 41px 27px;
}
}
}
}
=> ๊ฑฐ ์ด๋ค๋ณด๋ฉด TIL ์ด๋ฐ๊ฑฐ ์ข ๋ฐ๋ฆด ์ ์์ง ๋ญ, ์ด์งํผ ๊ณ์ ์ฑ์ธ๊ฑด๋ฐ ๋ญ๊ฐ ๋ฌธ์ ๋์์