/* General Body Styles */
html {
    scrollbar-gutter: stable both-edges;
}
body {
    font-family: 'Noto Sans KR', 'Inter', sans-serif;
    -webkit-tap-highlight-color: transparent;
    /* background-color is handled by theme classes */
    overflow-x: hidden;
    overflow-y: scroll; /* Keep vertical scrollbar space reserved */
}

/* App Container */
#app-container {
    width: 100%;   
    background-color: white;
    min-height: 100vh;
    box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    position: relative;    
    overflow-y: auto;
    margin: 0 auto; /* Center the container by default */
    display: flex; /* 콘텐츠가 적어도 사업자 정보가 하단에 붙도록 설정 */
    flex-direction: column;
    scrollbar-gutter: stable; /* Prevent layout shift when inner scrollbar appears */
  
}

main {
    flex-grow: 1; /* 메인 콘텐츠가 남은 공간을 모두 차지하도록 설정 */
}

/* Scrollbar Hiding */
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* Page Transition */
.page {
    display: block;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Header - Most styles are handled by utility classes in header.php */
header {
    background-color: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(4px);
    position: sticky;
    top: 0;
    z-index: 20;
    border-bottom: 1px solid #f3f4f6; /* border-gray-100 */
}

/* Site Logo scale */
.site-logo {
    max-height: 54px; /* ~22px, 기존 32px 대비 약 30% 축소 */
    max-width: 150px;

}

/* Footer Navigation */
footer#main-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    margin-left: auto;
    margin-right: auto;
    width: 100%;
    z-index: 20;
    box-shadow: 0 -4px 6px -1px rgb(0 0 0 / 0.1), 0 -2px 4px -2px rgb(0 0 0 / 0.1);
    background-color: white;
}

footer .nav-item.active i,
footer .nav-item.active span {
    color: #c2410c; /* orange-700 */
}

footer .nav-item span {
    white-space: nowrap; /* Prevent text from wrapping */
}

/* Bottom nav subtle motion */
footer .nav-item {
    transition: transform 0.15s ease, color 0.15s ease, opacity 0.15s ease;
    will-change: transform;
}
footer .nav-item:active {
    transform: translateY(2px) scale(0.98);
}
footer .nav-item.active {
    transform: translateY(-2px);
}

/* Form Styles for Login, Register etc. */
.form-label {
    display: block;
    font-size: 0.875rem; /* text-sm */
    font-weight: 500;
    color: #374151; /* text-gray-700 */
}

.form-input {
    margin-top: 0.25rem;
    display: block;
    width: 100%;
    padding: 0.5rem 0.75rem;
    background-color: white;
    border: 1px solid #d1d5db; /* border-gray-300 */
    border-radius: 0.375rem; /* rounded-md */
    box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
}
.form-input:focus {
    outline: none;
    --tw-ring-color: #fb923c; /* ring-amber-500 */
    --tw-border-color: #fb923c; /* border-amber-500 */
    box-shadow: 0 0 0 2px var(--tw-ring-color);
    border-color: var(--tw-border-color);
}

.form-button {
    margin-top: 1.5rem;
    width: 100%;
    background-color: #ea580c; /* bg-orange-600 */
    color: white;
    font-weight: 700;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem; /* rounded-lg */
    transition: background-color 0.2s;
}
.form-button:hover {
    background-color: #c2410c; /* hover:bg-orange-700 */
}

/* Alert/Message boxes */
.alert {
    padding: 1rem;
    border-radius: 0.5rem;
    margin-bottom: 1rem;
    font-weight: 500;
    border-width: 1px;
}
.alert-success {
    background-color: #dcfce7; /* bg-green-100 */
    color: #166534; /* text-green-800 */
    border-color: #4ade80; /* border-green-400 */
}
.alert-danger {
    background-color: #fee2e2; /* bg-red-100 */
    color: #991b1b; /* text-red-800 */
    border-color: #f87171; /* border-red-400 */
}

/* Swiper Banner */
.main-banner {
    position: relative;
}
.main-banner::before {
    content: "";
    display: block;
    padding-top: 100%; /* 1:1 aspect ratio */
}
.main-banner .swiper-wrapper {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
}
.main-banner .swiper-slide,
.main-banner .swiper-slide a {
    width: 100%;
    height: 100%;
}
.main-banner .swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.main-banner .swiper-pagination {
    bottom: 25px !important;
    left: 15px !important;
    width: auto !important;
    text-align: center;
    background-color: rgba(0, 0, 0, 0.3);
    color: white;
    padding: 2px 10px;
    border-radius: 20px;
    box-sizing: border-box;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Swiper Pagination dots color */
.swiper-pagination-bullet-active {
    background-color: #ea580c !important; /* orange-600 */
}

/* Pattern background (theme-less) */
@media (min-width: 1024px) {
    body {
        background-color: #f9fafb; /* bg-gray-50 */
        background-image: none !important;
    }
    body.pattern-on { background-image: var(--pattern-bg, none) !important; }
    body.pattern-on.pattern-paw { --pattern-bg: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80' viewBox='0 0 100 100'%3E%3Cpath d='M22.4 36.5c-2.9-2.9-2.9-7.5 0-10.4 2.9-2.9 7.5-2.9 10.4 0 2.9 2.9 2.9 7.5 0 10.4-2.9 2.8-7.5 2.8-10.4 0zM48 25.6c0-1.8-1.4-3.2-3.2-3.2s-3.2 1.4-3.2 3.2v6.4c0 5.3-4.3 9.6-9.6 9.6h-1.6c-5.3 0-9.6-4.3-9.6-9.6v-3.2c0-1.8-1.4-3.2-3.2-3.2s-3.2 1.4-3.2 3.2v3.2c0 8.8 7.2 16 16 16h1.6c8.8 0 16-7.2 16-16v-6.4zM12.8 16c0-5.3 4.3-9.6 9.6-9.6h1.6c5.3 0 9.6 4.3 9.6 9.6v3.2c0 1.8 1.4 3.2 3.2 3.2s3.2-1.4 3.2-3.2v-3.2zM6.4 25.6c0-1.8-1.4-3.2-3.2-3.2S0 23.8 0 25.6v6.4c0 5.3 4.3 9.6 9.6 9.6h1.6c1.8 0 3.2-1.4 3.2-3.2s-1.4-3.2-3.2-3.2h-1.6c-1.8 0-3.2-1.4-3.2-3.2v-6.4z' fill='%23e2e8f0' transform='scale(1.5) rotate(25 50 50)'/%3E%3C/svg%3E"); }
    body.pattern-on.pattern-dots { --pattern-bg: radial-gradient(circle at 20px 20px, #e5e7eb 2px, transparent 2px), radial-gradient(circle at 60px 60px, #e5e7eb 2px, transparent 2px); background-size: 80px 80px, 80px 80px; }
    body.pattern-on.pattern-grid { --pattern-bg: linear-gradient(transparent 79px, #e5e7eb 1px), linear-gradient(90deg, transparent 79px, #e5e7eb 1px); background-size: 80px 80px; }

  
}
 
 @layer base {
            /*
              [수정된 부분]
              Tailwind v4의 기본 테두리 색상 문제를 해결하기 위한 더 안정적인 선택자입니다.
              모든 요소(*)뿐만 아니라 ::before, ::after 같은 가상 요소까지 포함하여
              더 광범위한 경우에 일관된 기본 색상을 적용합니다.
            */
            *,
            ::before,
            ::after {
                 border-color: #e5e7eb; 
            }
        }