/* ===== 공통 박스 크기 설정 ===== */
* {
    box-sizing: border-box;
}

/* ===== 기본 배경 및 글꼴 ===== */
body {
    margin: 0;
    background: #fff;
    color: #514236;
    font-family: Arial,sans-serif;
}

/* ===== 전체 화면 최대 너비 ===== */
#app {
    max-width: 720px;
    margin: auto;
}

/* ===== 숨김 요소 처리 ===== */
[hidden] {
    display: none!important;
}

/* ===== 이미지 영역 ===== */
.picture {
    position: relative;
}

/* ===== 이미지 크기 ===== */
.picture img {
    display: block;
    width: 100%;
    height: auto;
}

/* ===== 투명 클릭 버튼 ===== */
.hot {
    position: absolute;
    background: transparent;
    border: 0;
    cursor: pointer;
    padding: 0;
}

/* ===== 키보드 포커스 표시 ===== */
.hot:focus-visible {
    outline: 2px solid #916b42;
}

/* ===== 메인 언어 버튼 공통 위치 ===== */
#home .hot {
    left: 20%;
    width: 60%;
    height: 8%;
}

/* ===== 영어 버튼 위치 ===== */
.english {
    top: 35%;
}

/* ===== 간체 버튼 위치 ===== */
.simplified {
    top: 45%;
}

/* ===== 번체 버튼 위치 ===== */
.traditional {
    top: 55%;
}

/* ===== 일본어 버튼 위치 ===== */
.japanese {
    top: 65%;
}

/* ===== 카테고리 메뉴 기본 설정 ===== */
#categories {
    position: sticky;
    top: 0;
    z-index: 5;
    display: grid;
    grid-template-columns: repeat(4,minmax(0,1fr));
    gap: 4px;
    padding: 6px 6px 12px;
    background: #fff;
    border-bottom: 1px solid #d6c3ad;
}

/* ===== 카테고리 버튼 디자인 ===== */
#categories button {
    border: 1px solid #e3d6c6;
    background: #f8f5f0;
    color: #514236;
    border-radius: 4px;
    padding: 8px 2px;
font-size: clamp(8px,2.3vw,14px);
white-space: nowrap;
min-height: 40px;
    cursor: pointer;
}

/* ===== 선택된 카테고리 ===== */
#categories button.active {
    background: #bfa17e;
    color: white;
    border-color: #bfa17e;
}

/* ===== 언어 버튼 기본 위치 ===== */
#language {
    right: 1%;
    top: 0;
    width: 27%;
    height: 7%;
}

/* ===== 안내 문구 ===== */
#notice {
    padding: 12px;
    text-align: center;
}

/* ===== 언어 선택창 기본 설정 ===== */
#languageList {
    position: absolute;
    right: 2%;
    top: 0;
    transform: translateY(var(--language-offset, 44px));
    z-index: 4;
    width: max-content;
    min-width: 130px;
    background: white;
    border: 1px solid #d6c3ad;
    border-radius: 5px;
    box-shadow: 0 4px 12px #0002;
    padding: 4px;
}

/* ===== 언어 선택창 버튼 ===== */
#languageList button {
    display: block;
    width: 100%;
    text-align: left;
    background: white;
    border: 0;
    border-bottom: 1px solid #eee5da;
    padding: 12px;
    color: #514236;
    font-family: sans-serif;
    font-size: 16px;
    font-weight: 500;
    letter-spacing: 0.5px;
    cursor: pointer;
}

/* ===== 마지막 버튼 테두리 제거 ===== */
#languageList button:last-of-type {
    border-bottom: 0;
}

/* ===== 언어 버튼 마우스 효과 ===== */
#languageList button:hover {
    background: #f8f5f0;
}

/* ===== 언어 준비 중 안내 ===== */
#languageNotice {
    display: block;
    padding: 8px;
    color: #916b42;
}

/* ===== 상단 고정 헤더 ===== */
#menuHeader {
    position: sticky;
    top: 0;
    z-index: 10;
    background: white;
}

/* ===== 카테고리 위치 재설정 ===== */
#categories {
    position: static;
}

/* ===== 상단 메뉴바 ===== */
.menuBar {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 0px 4px;
    background: white;
}

/* ===== 1인 1메뉴 주문 안내 ===== */
.order {
    background: #bfa17e;
    color: white;
    border-radius: 0 6px 6px 0;
    width: 50%;
    padding: 9px 0;
    text-align: center;
    font-size: clamp(10px,2.8vw,19px);
    letter-spacing: 2px;
    font-weight: 500;
}

/* ===== 언어 버튼 최종 디자인 ===== */
#language {
    position: static;
    width: auto;
    height: auto;
    border: 0;
    background: white;
    color: #514236;
    font-size: clamp(13px,3.2vw,20px);
    letter-spacing: 1px;
    padding: 10px 6px;
    cursor: pointer;
}

/* ===== 언어 선택창 최종 위치 ===== */
#languageList {
    top: 100%;
    right: 6px;
    transform: none;
    z-index: 20;
}
/* ===== 서브페이지 상단 라운드 이미지 ===== */

.menuTop {
    display: block;
    width: 100%;
    height: auto;
}


/* ===== 서브페이지 반복 배경 ===== */

.menuBody {
    background-image: url("img/bg.gif");
    background-repeat: repeat-y;
    background-position: top center;
    background-size: 100% auto;
}


/* ===== 서브페이지 메뉴 이미지 ===== */

.menuBody img {
    display: block;
    width: 100%;
    height: auto;
}

/* ===== 메인페이지 상단 및 하단 이미지 ===== */

.mainTop,
.mainBottom {
    display: block;
    width: 100%;
    height: auto;
}


/* ===== 메인페이지 반복 배경 ===== */

.mainBody {
    background-image: url("img/m_bg.gif");
    background-repeat: repeat-y;
    background-position: top center;
    background-size: 100% auto;

    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;              /* 버튼 사이 간격 */
    padding: 20px 0;        /* 상하 여백 */
}


/* ===== 메인페이지 언어 선택 버튼 ===== */

.mainBody button {
    position: relative;
    width: 55%;             /* 버튼 가로 너비 */
    padding: 12px 0;        /* 버튼 상하 여백 */
    background: #bfa17e;    /* 버튼 배경색 */
    color: white;           /* 글씨 색상 */
    border: 0;
    border-radius: 6px;     /* 모서리 라운드 */
    font-size: clamp(16px, 4vw, 26px);
    letter-spacing: 1px;
    cursor: pointer;
}


/* ===== 언어 버튼 오른쪽 화살표 ===== */

.mainBody button::after {
    content: "▸";
    position: absolute;
    right: 10%;
    top: 50%;
    transform: translateY(-50%);
}

/* ===== 언어 버튼 지구본 정렬 ===== */
#language {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

#language svg {
    width: 1em;
    height: 1em;
    flex-shrink: 0;
    margin: 0 !important;
}

/* ===== 메인페이지 상단 이미지 고정 ===== */
.mainTop {
    position: sticky;
    top: 0;
    z-index: 10;
    background: white;
}