/* Main Container: One Screen Layout */
.ll-app {
    display: flex;
    flex-direction: column;
    height: 100vh;
    /* 모바일 브라우저 주소창 이슈 해결용 */
    height: 100dvh; 
    overflow: hidden;
    background-color: #f5f6fa;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* 중간 스크롤 영역 */
.ll-container {
    flex: 1;
    overflow-y: auto;
    padding: 0 16px; /* 좌우 여백 통일 */
    padding-bottom: 80px; /* 탭바 높이만큼 여백 확보 */
    -webkit-overflow-scrolling: touch;
}

/* Header - 고정 */
.ll-header {
    flex: 0 0 auto;
    position: relative;
    z-index: 100;
    background: #f5f6fa;
    padding: 6px 16px;
}

/* Footer Tabbar (F Layer) - 하단 고정 스타일 */
.ll-tabbar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 60px; /* 높이 고정 */
    background: #ffffff;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 900;
    padding-bottom: env(safe-area-inset-bottom); /* 아이폰 하단 바 대응 */
    box-shadow: 0 -2px 10px rgba(0,0,0,0.03);
}

.ll-tab-item {
    flex: 1;
    height: 100%;
    border: none;
    background: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #999;
    cursor: pointer;
    padding: 0;
}

.ll-tab-item i { /* 대시아이콘 크기 */
    font-size: 22px;
    margin-bottom: 4px;
    display: block;
    width: 24px;
    height: 24px;
    line-height: 24px;
    text-align: center;
}

.ll-tab-item span {
    font-size: 11px;
    font-weight: 500;
}

/* 활성 탭 스타일 */
.ll-tab-item.is-active {
    color: #4b7bec; /* 메인 컬러 */
}
.ll-tab-item.is-active i {
    color: #4b7bec;
}

/* 오버레이 등 기존 스타일 유지 */
.ll-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: flex-end; /* 바텀 시트 기본 */
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.3s, visibility 0.3s;
}

.ll-overlay.is-open {
    visibility: visible;
    opacity: 1;
}

.ll-overlay-content {
    background: #fff;
    width: 100%;
    max-width: 600px; /* 태블릿 대응 */
    border-radius: 20px 20px 0 0;
    padding: 20px;
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

.ll-overlay.is-open .ll-overlay-content {
    transform: translateY(0);
}

/* 로딩 스피너 */
.ll-spinner {
    width: 24px; height: 24px;
    border: 3px solid #eee;
    border-top-color: #4b7bec;
    border-radius: 50%;
    animation: ll-spin 0.8s linear infinite;
}
@keyframes ll-spin { to { transform: rotate(360deg); } }

/* * [NEW] Floating Calculator Button 
 * 하단 탭바 바로 위에 뜨는 작은 알약 버튼
 */
.ll-floating-btn {
    position: fixed;
    bottom: 75px; /* 탭바(60px) + 여유(15px) */
    left: 50%;
    transform: translateX(-50%);
    z-index: 850; /* 탭바(900)보다 아래, 컨텐츠보다 위 */
    
    display: flex;
    align-items: center;
    gap: 6px;
    
    background: #ffffff;
    color: #4b7bec;
    border: 1px solid #e5edff;
    padding: 8px 16px;
    border-radius: 30px;
    
    box-shadow: 0 4px 12px rgba(75, 123, 236, 0.15);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.ll-floating-btn:active {
    transform: translateX(-50%) scale(0.95);
    background: #f5f6fa;
}

.ll-floating-btn .icon {
    font-size: 16px;
}