@font-face {
	font-family: 'NanumGothic';
	src: url('/fonts/NanumGothic.woff2') format('woff2'),
		url('/fonts/NanumGothic.woff') format('woff');
	font-weight: normal;
	font-style: normal;
}


	@font-face {
    font-family: 'BMJUA';
    src: url('https://fastly.jsdelivr.net/gh/projectnoonnu/noonfonts_one@1.0/BMJUA.woff') format('woff');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'RecipeKorea';
    src: url('/fonts/Recipekorea.otf');
    font-weight: normal;
    font-style: normal;
}
.title_font{
	font-family: 'RecipeKorea','BMJUA', sans-serif;
	
}

body{
		font-family: 'BMJUA','NanumGothic', sans-serif;
}



.tag_body {
    margin: 0;
    padding: 0; 
    display: flex;
    justify-content: center;
    align-items: center; 
    overflow: auto;
    background: url("/img/background/tage.jpg") no-repeat center/cover;
    
  }
  .stack-container {
    position: relative;
    width: 330px;
    height: 100px;
    top: 10px;
  }
  p {
      margin-top: 0;
      margin-bottom: 0rem !important;
  }
  .profile {
    width: 330px;
    height: 100px;
    background: #fafafa;
    border-radius: 5px;
    box-shadow: 0 0 2rem #babbbc;
    position: absolute;
    left: 0;
    transform: translateY(0);
    transition: transform 0.5s ease, opacity 0.4s ease;
  } 
  .photo {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    overflow: hidden;
    border: 5px solid #fafafa;
    margin-left: -50px;
    background: #fafafa;
    box-shadow: 0 0 .5rem #babbbc;
    float: left;
    position: relative;
    z-index: 2;
  }
  .photo img {
    width: 100%;
  }
  .content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 10px;
    box-sizing: border-box;
    z-index: 1;
    overflow: hidden;
  }
  .content::before {
    content: '';
    position: absolute;
    width: 230px;
    height: 150px;
    background-color: #e9f3e6;
    left: 0;
    top: -20px;
    transform: rotate(-8deg);
    z-index: -1;
  }
  .text {
    margin-top: 20px;
    margin-left: 60px;
  }
  .text h3, .text h6 {
    margin: 0;
  }
  .btn {
    background: #abc;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    position: absolute;
    right: 25px;
    top: 25px;
    cursor: pointer;
    z-index: 5;
    transition: all 0.3s ease-in-out;
  }
  .btn span,
  .btn span::before,
  .btn span::after {
    background: white;
    height: 2px;
    position: absolute;
    width: 60%;
    left: 20%;
    top: 50%;
    transform: translateY(-50%);
    content: '';
    display: block;
    transition: 0.3s;
  }
  .btn span::before { margin-top: -7px; }
  .btn span::after { margin-top: 7px; }
  .btn.active span { transform: rotate(180deg); }
  .btn.active span::before { transform: rotate(45deg); }
  .btn.active span::after { transform: rotate(-45deg); }
  .box {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background-color: rgba(255,255,255,0.7);
    position: absolute;
    top: 50%;
    right: -44%;
    transform: translate(-50%, -50%);
    opacity: 0;
    transition: 0.3s ease-in-out;
    z-index: -2;
    pointer-events: none;
  }
  .box i {
    width: 50px;
    height: 50px;
    background: #ececec;
    border-radius: 50%;
    text-align: center;
    line-height: 50px;
    font-size: 22px;
    position: absolute;
    top: calc(75px - 25px);
    left: 60px;
    transition: 0.3s;
    box-shadow: 0 0 .5rem #babbbc;
  }
  .tag-limit {
    max-width: 150px;       /* 원하는 최대 너비 */
    overflow: hidden;       /* 넘치는 부분 숨기기 */
    text-overflow: ellipsis;/* 말줄임표(...) */
    white-space: nowrap;    /* 줄바꿈 방지 */
  }
  tag-card-limit{
    max-width: 200px;       /* 원하는 최대 너비 */
    overflow: hidden;       /* 넘치는 부분 숨기기 */
    text-overflow: ellipsis;/* 말줄임표(...) */
    white-space: nowrap;    /* 줄바꿈 방지 */
    
  }
       
  .box.open { opacity: 1; pointer-events: auto; }
  .box.open a:nth-child(1) i { transform: rotate(-90deg) translateX(120px) rotate(90deg); transition-delay: 0.1s; }
  .box.open a:nth-child(2) i { transform: rotate(-45deg) translateX(120px) rotate(45deg); transition-delay: 0.2s; }
  .box.open a:nth-child(3) i { transform: rotate(0deg) translateX(120px) rotate(0deg); transition-delay: 0.3s;    }
  .box.open a:nth-child(4) i { transform: rotate(45deg) translateX(120px) rotate(-45deg); transition-delay: 0.4s; }
  .box.open a:nth-child(5) i { transform: rotate(90deg) translateX(120px) rotate(-90deg); transition-delay: 0.5s; }
  
  .profile:hover {
    transform: translateY(-10px) scale(1.02);
    z-index: 10;
  }   
  .username_img  { width: 28px; position: absolute; top: 11px; left: 12px; color: #ff8f00;}
  .facebook_img  { width: 28px; position: absolute; top: 11px; left: 12px; color: #3B5998;}
  .youtube_img   { width: 28px; position: absolute; top: 11px; left: 12px; color: #FF0000;}
  .instagram_img { width: 28px; position: absolute; top: 11px; left: 12px; }
  .twitter_img   { width: 28px; position: absolute; top: 11px; left: 12px; color: #000000;}
  
  .profile-circle {
        width: 100px;
        height: 100px;
        border-radius: 50%;
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
      } 	
  /* card-body는 이미지보다 위에 있게 */
	.card {
	text-decoration: none; /* 링크의 밑줄 제거 */
	color: inherit; /* 카드 내부 텍스트 색상 유지 */
}

.card:hover {
	cursor: pointer; /* 마우스 오버 시 손 모양 커서 표시 */
}

.card:hover .card-img-top {
	transform: scale(1.05); /* 마우스 오버 시 이미지 확대 */
}

/* 일반 레시피 스타일 */
a {
	text-decoration: none;
	color: inherit;
}

a:hover {
	text-decoration: none;
	color: inherit;
}

.masonry-item {
	display: flex;


}

.card {
	height: 100%;
	overflow: hidden;
	border-radius: 8px;
	box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
	transition: transform 0.3s ease;
	position: relative; /* 필요 시 포지셔닝 기준 */
	border-color: rgba(0,0,0,0.3) !important;
	width: 100%;

}
.img-container{
	position: relative;
}
.card-rate{
	position: absolute;
	top: 10px;
	left: 10px;
	text-shadow: -1px 0px black, 0px 1px black, 1px 0px black, 0px -1px black;
}

.card-views{
	position: absolute;
	top: 10px;
	right: 10px;
	text-shadow: -1px 0px black, 0px 1px black, 1px 0px black, 0px -1px black;
}

.card-difficulty{
	position: absolute;
	bottom: 10px;
	left: 10px;
	opacity: 1;
	transition: opacity 0.3s ease; /* opacity에 애니메이션 추가 */
	text-shadow: -1px 0px black, 0px 1px black, 1px 0px black, 0px -1px black;
}

.card:hover .card-difficulty{
	opacity: 0;
}

.card-cookingtime{
	position: absolute;
	bottom: 10px;
	right: 10px;
	opacity: 1;
	transition: opacity 0.3s ease; /* opacity에 애니메이션 추가 */
	text-shadow: -1px 0px black, 0px 1px black, 1px 0px black, 0px -1px black;
}

.card:hover .card-cookingtime{
	opacity: 0;
}




.card-ingredients{
	position: absolute;
	bottom: 10px;
	left: 10px;
	opacity: 0;
	transition: opacity 0.3s ease; /* opacity에 애니메이션 추가 */
}

.card:hover .card-ingredients{
	opacity: 1;
}
.card-img-top {
    width: 100%;
    aspect-ratio: 1 / 1; /* 1:1 비율 유지 */
    object-fit: cover;
    transition: transform 0.3s ease;
}

.card-body {
	padding: 15px;
	
}

.card-title {
	font-size: 1.2rem;
	font-weight: bold;
}

.card-text {
	color: #555;
	font-size: 0.9rem;
}

.card:hover .card-img-top {
	transform: scale(1.02);
}

.card:hover{
	transform: scale(1.02);
}

  .card-body {
    position: relative;
    z-index: 2;
    background-color: rgba(255, 255, 255, 0.9); /* 필요시 배경 흐리게 */
  }	
  .card-info-rows {
    display: flex;
    flex-direction: column;
    gap: 6px;
  } 
  .card-text {
    margin-bottom: 0;
  }
  .fa-star{
      color:#f5cd33;
  }
  
  .info-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
  }
  
  /* 평점을 오른쪽 끝으로 밀기 (Bootstrap 안 쓰면 이렇게!) */
  .info-row:last-child {
    justify-content: space-between;
  }

  #wrap{
      display: table;
      height: 100%;
      position: relative;
      min-height: 100vh;
      min-width: 640px;
  }
  .section{
      display: table-cell;
      width: 395px;
      z-index: 1;
      background-color: #fff;
      padding-top: 50px;
      position: relative ;
      top:-100px;
  }
  #cardList1{
      display: table-cell;
      width: 100%;
      vertical-align: top;
      overflow-y: auto;       
      max-height: 100vh;      
      padding: 2rem;
  }
  
  
  
  #cardList1::-webkit-scrollbar {
    width: 8px;
  }
  #cardList1::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
  }
  /* 카드 클릭 관련 효과  */
  .clickable-card {
      cursor: pointer;
      transition: transform 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
    }
  
    .clickable-card:hover {
      transform: scale(1.02);
      box-shadow: 0 6px 18px rgba(0, 0, 0, 0.15);
    }
      footer{
          position: relative;
          bottom: 0px;
          width: 100%;
      }
      
      /* 사이드바 기본 스타일 */
      .sidebar {
        width: 600px;
        background-color: #ffffff;
        box-shadow: 2px 0 8px rgba(0, 0, 0, 0.1);
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        padding-top: 80px;
        z-index: 100;
      }
      
      /* 사이드바 메뉴 스타일 */
      .sidebar-menu {
        list-style: none;
        padding: 0;
        margin: 0;
      }
      
      .sidebar-menu li {
        margin: 20px 0;
        text-align: center;
      }
      
      .sidebar-menu a {
        text-decoration: none;
        color: #333;
        font-weight: bold;
      }
      
      /* wrap에 좌측 여백 줘야 content가 사이드바 안 덮임 */
      #wrap {
        margin-left: 200px;
      }
      #cardContainer2{
          position: relative;
          width: 330px;
          height: 100px;
          top: 100px;
          margin: 0 auto;
      }
      
      /* 사이드바 태그목록 ===================================================== */
      .sidebar {
        overflow-y: auto;
        height: 100vh;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
      }
      .profile2 {
        width: 330px;
        height: 100px;
        background: #fafafa;
        border-radius: 5px;
        box-shadow: 0 0 2rem #babbbc;
        position: absolute;
        left: 0;
        transform: translateY(0);
        transition: transform 0.5s ease, opacity 0.4s ease;
      } 
      .photo {
        width: 110px;
        height: 110px;
        border-radius: 50%;
        overflow: hidden;
        border: 5px solid #fafafa;
        margin-left: -50px;
        background: #fafafa;
        box-shadow: 0 0 .5rem #babbbc;
        float: left;
        position: relative;
        z-index: 2;
      }
      .photo img {
        width: 100%;
      }
      .content {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        padding: 10px;
        box-sizing: border-box;
        z-index: 1;
        overflow: hidden;
      }
      .content::before {
        content: '';
        position: absolute;
        width: 230px;
        height: 150px;
        background-color: #e9f3e6;
        left: 0;
        top: -20px;
        transform: rotate(-8deg);
        z-index: -1;
      }
      .text {
        margin-top: 20px;
        margin-left: 60px;
      }
      .text h3, .text h6 {
        margin: 0;
      }
      .btn {
        background: #abc;
        width: 50px;
        height: 50px;
        border-radius: 50%;
        position: absolute;
        right: 25px;
        top: 25px;
        cursor: pointer;
        z-index: 5;
        transition: all 0.3s ease-in-out;
      }
      .btn span,
      .btn span::before,
      .btn span::after {
        background: white;
        height: 2px;
        position: absolute;
        width: 60%;
        left: 20%;
        top: 50%;
        transform: translateY(-50%);
        content: '';
        display: block;
        transition: 0.3s;
      }
      .btn span::before { margin-top: -7px; }
      .btn span::after { margin-top: 7px; }
      .btn.active span { transform: rotate(180deg); }
      .btn.active span::before { transform: rotate(45deg); }
      .btn.active span::after { transform: rotate(-45deg); }
      .box2 {
        width: 150px;
        height: 150px;
        border-radius: 50%;
        background-color: rgba(255,255,255,0.7);
        position: absolute;
        top: 50%;
        right: -44%;
        transform: translate(-50%, -50%);
        opacity: 0;
        transition: 0.3s ease-in-out;
        z-index: -2;
        pointer-events: none;
      }
      .box2 i {
        width: 50px;
        height: 50px;
        background: #ececec;
        border-radius: 50%;
        text-align: center;
        line-height: 50px;
        font-size: 22px;
        position: absolute;
        top: calc(75px - 25px);
        left: 60px;
        transition: 0.3s;
        box-shadow: 0 0 .5rem #babbbc;
      }
      #toggleSidebar{
              position: fixed;
              top: 110px;
              width: 50px;
              height: 50px;
              border: 2px solid #43d743;
              background-color: #009f00;
                  z-index: 9999;
      }
      .tag-limit {
        max-width: 150px;       /* 원하는 최대 너비 */
        overflow: hidden;       /* 넘치는 부분 숨기기 */
        text-overflow: ellipsis;/* 말줄임표(...) */
        white-space: nowrap;    /* 줄바꿈 방지 */
      }
      tag-card-limit{
        max-width: 200px;       /* 원하는 최대 너비 */
        overflow: hidden;       /* 넘치는 부분 숨기기 */
        text-overflow: ellipsis;/* 말줄임표(...) */
        white-space: nowrap;    /* 줄바꿈 방지 */
        
      }
           
      .box2.open { opacity: 1; pointer-events: auto; }
      .box2.open a:nth-child(1) i { transform: rotate(0deg) translateY(0px) rotate(0deg); transition-delay: 0.1s; }
      .box2.open a:nth-child(2) i { transform: rotate(0deg) translateY(55px) rotate(0deg); transition-delay: 0.2s; }
      .box2.open a:nth-child(3) i { transform: rotate(0deg) translateY(110px) rotate(0deg); transition-delay: 0.3s;    }
      .box2.open a:nth-child(4) i { transform: rotate(0deg) translateY(165px) rotate(0deg); transition-delay: 0.4s; }
      .box2.open a:nth-child(5) i { transform: rotate(0deg) translateY(220px) rotate(0deg); transition-delay: 0.5s; }
      .profile2:hover {
        transform: translateY(-10px) scale(1.02);
        z-index: 10;
      }   
      .username_img  { width: 28px; position: absolute; top: 11px; left: 12px; color: #ff8f00;}
      .facebook_img  { width: 28px; position: absolute; top: 11px; left: 12px; color: #3B5998;}
      .youtube_img   { width: 28px; position: absolute; top: 11px; left: 12px; color: #FF0000;}
      .instagram_img { width: 28px; position: absolute; top: 11px; left: 12px; }
      .twitter_img   { width: 28px; position: absolute; top: 11px; left: 12px; color: #000000;}
      
      .profile2-circle {
            width: 100px;
            height: 100px;
            border-radius: 50%;
            background-size: cover;
            background-position: center;
            background-repeat: no-repeat;
      } 
      
      
      /* ✅ 반응형 스타일 추가 */
      @media (max-width: 1169px) {
 		.masonry-container {
 		grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
 		}
}
      
      @media (max-width: 883px) {
      	.desktop-user{
      	    margin-left: 3rem !important;
      	}
      }
      @media (max-width: 768px) {
        #wrap {
          margin-top: 1rem; 
        }
      
         .section {
          display: none !important;
          width: 100%;
          margin: 0 auto;
          z-index: -1;
          position: relative;
          top:-100px;
        }
        
        .desktop-user{
			display: none;
		}
                      
          #cardList1 {
          display: block;
          width: 100%;
          clear: both;
          z-index: 50;
          margin: 15px !important;
		  padding: 0px;
          min-width: 0px !important;
          padding-top: 0px!important;
          margin-top: 0px !important;
          height: 150vh;
        }
        
        .masonry-container{
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)) !important;
        }
        
        .masonry-item{
        	padding: 15px!important
        }
        
      .section .profile {
          /* display: none !important; */
        }	
         #cardContainer {
          display: none !important;
          
        } 
        
        .card{
        	margin: 0px!important;
        	
        	}
      }
      
            @media (max-width: 650px) {
              #cardList1 {
              	width: 60%;
              	padding-left: 5px;
          		padding-right: 5px;
				margin: 0 auto !important;
				padding-top: 0px !important;
				height: 100%;
              }
            
            
            }
      
      /* ✅ 모바일에서 사이드바 숨기기 */
      

        

      
      @media (max-width: 883px) {
        .sidebar {

          transform: translateX(-100%);
          transition: transform 0.3s ease;
        }
       /* 토글되면 자연스럽게 슬라이드 인 */
      .sidebar.sidebar-open {
        transform: translateX(0);
      }
        #wrap {
          margin-left: 0;
        }
      }
      /*토글버튼 */
      .sidebar.closed {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
      }
      #sidebarToggle {
        position: fixed;
        top: 200px;
        right: 200px; /* 👈 왼쪽에서 오른쪽으로 변경 */
        z-index: 9999;
      }
      /* 모바일일 때 자동 줄이기 임*/
      @media (max-width: 768px) {
        .sidebar {
          width: 432px;
        }
      
        .sidebar.collapsed {
          width: 0;
        }
        .card {
	height: 100%;}
        
        .cardLink{
                margin: auto 50px auto 60px;
        }
      }
      
      @media (max-width: 450px) {
		.sidebar {
       		width: 100%;
    	}
    	
    	.content::before{
    		width: 150px;
    	}
    	#cardContainer2{
    		width: 200px;
    	}
    	.profile2{
    		width: 230px;
    	}
    	.box2{
    	right: -74%
    	}
    	.btn{
    		top:15px;
    	}
      }
      
        @media (max-width: 385px) {
        .box2{
        right: -40%;
    	height: 0px;
    	}
        
        }
        
        
        .tagify {
	--tags-border-color: none;
	--tags-hover-border-color: none;
	--tags-focus-border-color: none;
	--tag-bg: #000000f0;
	--tag-hover: #000000f0;
	--tag-text-color: white;
	--tag-border-radius: 16px;
	border: none;
	border-radius: 16px !important;
}

.tag.tagify{
	text-shadow: -1px 0px black, 0px 1px black, 1px 0px black, 0px -1px black;
	--tag-bg:  #f0f0f0;
}

.ingredients.tagify[readonly] .tagify__tag > div::before {
			display:flex;
    content: "재료";
    font-size:0.7rem;
    color: var(--green);
    font-weight: bold;
}

.r_ingredients.tagify[readonly] .tagify__tag > div::before {
	display:flex;
    content: "재료";
    font-size:0.6rem;
    color: var(--green);
}
.tag .tagify__tag-text{
	font-size: 1.05rem;
}
      