/*
* style.css - Custom styles for God Of Lotto web service
*/

/* Google Fonts - Noto Sans KR */
body {
    font-family: 'Noto Sans KR', sans-serif;
    background-color: #F8F9FA;
    color: #343A40;
 /* ▼▼▼▼▼ [핵심 추가] 텍스트 선택 및 드래그 방지 ▼▼▼▼▼ */
    -webkit-user-select: none; /* Chrome, Safari, Opera */
    -moz-user-select: none;    /* Firefox */
    -ms-user-select: none;     /* Internet Explorer/Edge */
    user-select: none;         /* Standard syntax */
    -webkit-user-drag: none;   /* 이미지 등 드래그 방지 */
    /* ▲▲▲▲▲ [수정 완료] ▲▲▲▲▲ */
}

/* Navbar */
.navbar-brand {
    font-weight: 700;
}

/* Card styles */
.card {
    border-radius: 0.5rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

.card-header {
    font-weight: 600;
}

/* ========================================================== */
/*  Lotto Ball Styles (통합 및 개선 버전)                     */
/* ========================================================== */
.lotto-ball {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    color: white;
    font-weight: bold;
    font-size: 1rem;
    margin: 2px 3px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.4), inset 0 -2px 2px rgba(0,0,0,0.2);
    text-shadow: 0 0 3px rgba(0,0,0,0.5);
    border: 1px solid rgba(0,0,0,0.2);
}

/* 로또 공 색상 (그라데이션 효과) */
.lotto-ball.ball-yellow { background-image: radial-gradient(circle at 12px 12px, #ffee58, #fbc400); color: #343a40; }
.lotto-ball.ball-blue   { background-image: radial-gradient(circle at 12px 12px, #4fc3f7, #29b6f6); }
.lotto-ball.ball-red    { background-image: radial-gradient(circle at 12px 12px, #ef5350, #e53935); }
.lotto-ball.ball-gray   { background-image: radial-gradient(circle at 12px 12px, #bdbdbd, #757575); }
.lotto-ball.ball-green  { background-image: radial-gradient(circle at 12px 12px, #9ccc65, #7cb342); }
.lotto-ball.bonus-ball  { background-image: radial-gradient(circle at 12px 12px, #ffee58, #fbc400); color: #343a40; }


/* ========================================================== */
/*  Latest Draw Info Panel Styles                           */
/* ========================================================== */
.draw-info-card { display: flex; justify-content: space-between; align-items: flex-start; padding: 1rem; background-color: #e9ecef; border-radius: 0.3rem; margin-bottom: 1rem; }
.info-left { flex-grow: 1; }
.info-right { flex-shrink: 0; text-align: right; }
.draw-number-header { font-size: 1.75rem; font-weight: 700; color: #0d6efd; margin-bottom: 0.25rem; }
.draw-info-card p { margin-bottom: 0.5rem; }
.win-numbers { font-size: 1.25rem; font-weight: 500; }
.bonus-number { font-size: 1.1rem; font-weight: 500; }
.lotto-draw-navigation { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.75rem; }
.score-panel { background-color: rgba(255,255,255,0.5); padding: 0.5rem 1rem; border-radius: 0.25rem; }
.score-item { margin-bottom: 0.25rem; }
.score-label { font-size: 0.9rem; }
.score-value { font-weight: bold; font-size: 1rem; margin-left: 0.5rem; }
.score-current { color: #dc3545; }
.score-avg { color: #007bff; }
.pattern-details-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.75rem 1rem; padding: 1rem; border: 1px solid #dee2e6; border-radius: 0.3rem; }
.pattern-item { font-size: 0.9rem; display: flex; justify-content: space-between; border-bottom: 1px dotted #ccc; padding-bottom: 0.25rem; }
.pattern-full-width { grid-column: 1 / -1; }
.pattern-label { font-weight: 500; color: #495057; }
.pattern-value { font-weight: bold; }
.color-carryover { color: #6f42c1; }
.color-prime { color: #28a745; }
.color-composite { color: #8B0000; }
.color-prediction { color: #fd7e14; }

/* ========================================================== */
/*  Recommendation & Analysis Panel Styles                  */
/* ========================================================== */
.combo-item { padding: 6px 4px; border-bottom: 1px solid #eee; display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.combo-item:last-child { border-bottom: none; }
.combo-item .score { font-size: 0.9em; color: #6c757d; font-weight: normal; white-space: nowrap; }
.numbers-group { display: flex; gap: 5px; flex-wrap: nowrap; }
.analysis-log { background-color: #212529; color: #e2e6ea; padding: 1rem; border-radius: 0.3rem; font-family: 'Consolas', 'Monaco', 'monospace'; height: 100%; display: flex; flex-direction: column; }

/* ========================================================== */
/*  Advanced Settings & Overlays                            */
/* ========================================================== */

/* [신규 추가] 버튼에 붙이면 은은하게 반짝이며 시선을 끄는 범용 애니메이션 클래스 */
@keyframes pulse-anim-glow {
    0%   { box-shadow: 0 0 0 0 rgba(255, 193, 7, 0.6); transform: scale(1); }
    50%  { box-shadow: 0 0 0 10px rgba(255, 193, 7, 0); transform: scale(1.04); }
    100% { box-shadow: 0 0 0 0 rgba(255, 193, 7, 0); transform: scale(1); }
}
.pulse-anim {
    animation: pulse-anim-glow 1.6s infinite;
}

@keyframes pulse-glow {
    0% { box-shadow: 0 0 8px rgba(13, 110, 253, 0.4), 0 0 12px rgba(111, 66, 193, 0.3); }
    50% { box-shadow: 0 0 16px rgba(13, 110, 253, 0.7), 0 0 24px rgba(111, 66, 193, 0.5); }
    100% { box-shadow: 0 0 8px rgba(13, 110, 253, 0.4), 0 0 12px rgba(111, 66, 193, 0.3); }
}
#advancedSettingsAccordion .accordion-button { 
    background: linear-gradient(135deg, #0d6efd, #6f42c1); 
    color: #ffffff; 
    font-weight: bold; 
    border: none; 
    transition: all 0.3s ease; 
    display: flex; /* Flexbox 레이아웃 사용 */
    justify-content: center; /* 주 축(가로) 중앙 정렬 */
    align-items: center; /* 교차 축(세로) 중앙 정렬 */
    width: 100%;
    position: relative; /* 화살표 아이콘의 위치 기준점 */
}

#advancedSettingsAccordion .accordion-button:not(.collapsed) {
    color: #ffffff; 
    background: linear-gradient(135deg, #0d6efd, #6f42c1); 
    box-shadow: inset 0 -3px 5px rgba(0,0,0,0.2);
}

/* 화살표 아이콘은 오른쪽에 위치하도록 절대 위치 지정 */
#advancedSettingsAccordion .accordion-button::after { 
    filter: brightness(0) invert(1);
    position: absolute;
    right: 1.25rem; /* 오른쪽 여백 */
}
/* ▲▲▲▲▲ [수정 완료] ▲▲▲▲▲ */
#advancedSettingsAccordion .accordion-button.collapsed { animation: pulse-glow 2.5s infinite; }
#advancedSettingsAccordion .accordion-button:hover { transform: translateY(-2px); box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3); }
#advancedSettingsAccordion .accordion-button:not(.collapsed) { color: #ffffff; background: linear-gradient(135deg, #0d6efd, #6f42c1); box-shadow: inset 0 -3px 5px rgba(0,0,0,0.2); }
#advancedSettingsAccordion .accordion-button::after { filter: brightness(0) invert(1); }
#advancedSettingsAccordion .accordion-button:focus { box-shadow: 0 0 16px rgba(13, 110, 253, 0.7); border: none; }

.loading-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.7); display: flex; justify-content: center; align-items: center; z-index: 1050; flex-direction: column; }

/* ========================================================== */
/* 2단계 분석 UI 개선
/* ========================================================== */
.step2-info-panel { background-color: #f8f9fa; border: 1px solid #dee2e6; border-radius: .375rem; padding: .75rem 1rem; font-size: .875rem; }
.step2-info-panel div { margin-bottom: .25rem; }
fieldset.step2-filter-group { border: 1px solid #ced4da; border-radius: .375rem; padding: .75rem 1rem 1rem; }
fieldset.step2-filter-group legend { float: none; width: auto; padding: 0 .5rem; font-size: .9rem; font-weight: bold; }
.btn-gold { background-color: #ffc107; border-color: #ffc107; color: #000; font-weight: bold; }
.btn-gold:hover { background-color: #ffca2c; border-color: #ffc720; color: #000; }
.form-label-sm { margin-bottom: .2rem; }


/* ========================================================== */
/* ▼▼▼ [핵심 수정] CS 버전 현황표 스타일 (메인 패널용) ▼▼▼    */
/* ========================================================== */
.status-board-cs-wrapper {
    border: none;
    border-radius: 1rem;
    padding: 1.25rem;
    background: linear-gradient(180deg, #f8f9fc 0%, #eef0f5 100%);
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.04);
}
.status-board-cs-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    flex-wrap: wrap;
    gap: 1rem;
}
.status-board-cs-header h6 {
    margin-bottom: 0;
    font-size: 1rem;
    font-weight: bold;
}
.header-controls-cs {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.header-controls-cs input {
    width: 70px;
    border-radius: 50px !important;
}
.header-controls-cs button.btn {
    border-radius: 50px !important;
    font-weight: 700;
}
.status-board-cs-legend {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.5rem 0.6rem;
    border: none;
    background-color: #fff;
    border-radius: 50px;
    margin-bottom: 1rem;
    font-size: 0.72rem;
    overflow-x: auto;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.legend-cs-title {
    font-weight: bold;
    margin-right: 0.1rem;
    white-space: nowrap;
}
.legend-cs-item {
    padding: 0.12rem 0.5rem;
    border-radius: 50px;
    font-weight: 700;
    white-space: nowrap;
    flex-shrink: 0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}
.status-board-cs-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
}
.status-cell-cs {
    border: none;
    border-radius: 10px;
    text-align: center;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.status-cell-cs:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 14px rgba(0,0,0,0.15);
}
.cell-header-cs {
    font-weight: bold;
    padding: 5px;
    color: white;
    font-size: 0.9rem;
}
.cell-count-cs {
    font-size: 1.5rem;
    font-weight: bold;
    padding: 6px 4px;
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1.2;
}
.cell-count-cs small {
    font-size: 0.8rem;
    font-weight: normal;
    display: block;
    opacity: 0.8;
}
.cell-temp-cs {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.3px;
    padding: 4px;
    background-color: rgba(0,0,0,0.05);
    border-top: 1px solid rgba(0,0,0,0.06);
}
/* 로또볼 헤더 색상 */
.ball-header-yellow { background-color: #fbc400; color: #333; }
.ball-header-blue   { background-color: #69c8f2; }
.ball-header-red    { background-color: #ff7272; }
.ball-header-gray   { background-color: #aaa; }
.ball-header-green  { background-color: #b0d840; }


/* ========================================================== */
/* 미출현 현황표 모달 스타일 (기존 스타일 유지 및 일부 정리)      */
/* ========================================================== */
.status-board-wrapper {
    font-family: 'Malgun Gothic', '맑은 고딕', sans-serif;
}
.status-board-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 0.5rem;
    background-color: #f0f0f0;
    border-radius: 5px;
}
.status-board-legend {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-bottom: 1rem;
    font-size: 0.8rem;
}
.legend-title {
    font-weight: bold;
}
.legend-item {
    padding: 2px 8px;
    border-radius: 3px;
    border: 1px solid #ccc;
}
.status-board-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
    border: 1px solid #ccc;
    padding: 5px;
    background-color: #e9e9e9;
}
.status-cell {
    border: 1px solid #aaa;
    text-align: center;
    padding: 5px;
    border-radius: 4px;
    background-color: white;
}
.status-cell-num {
    font-weight: bold;
    font-size: 0.9rem;
    background-color: rgba(255, 255, 255, 0.3);
    border-radius: 3px 3px 0 0;
    padding: 2px;
    margin: -5px -5px 5px -5px;
    border-bottom: 1px solid #ccc;
}
.status-cell-count {
    font-size: 1.2rem;
    font-weight: bold;
}
.status-cell-count small {
    font-size: 0.75rem;
    font-weight: normal;
    color: #333;
}
.status-cell-temp {
    font-size: 0.7rem;
    font-style: italic;
    margin-top: 2px;
}

/* 10회차 동시보기 스타일 */
.multi-status-container {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}
.single-board-wrapper {
    flex: 1 1 48%; /* 2열 레이아웃 */
    border: 1px solid #dee2e6;
    padding: 10px;
    border-radius: 8px;
    background-color: #f8f9fa;
}
.single-board-wrapper h6 {
    text-align: center;
    margin-bottom: 10px;
    padding-bottom: 5px;
    border-bottom: 1px solid #ccc;
}
.multi-status-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 3px;
}
.multi-status-cell {
    border: 1px solid #ccc;
    text-align: center;
    padding-top: 2px;
    padding-bottom: 2px;
    font-size: 0.75rem;
    border-radius: 3px;
    line-height: 1.2;
}
.multi-status-cell .num {
    font-weight: bold;
}
.multi-status-cell .count {
    font-size: 0.9rem;
}
.multi-status-cell .count small {
    font-size: 0.65rem;
}

/* 반응형 웹 디자인 */
@media (max-width: 1200px) {
    #step2-main-container {
        flex-direction: column; /* 열을 세로로 쌓음 */
    }
}
/* ========================================================== */
/*  10회차 미출현 현황표 모달 스타일 (SVG 라인 추가)             */
/* ========================================================== */

#multiStatusModal .modal-dialog {
    max-width: 98vw;
}

.multi-status-container-5col {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
}
@media (max-width: 1200px) {
    .multi-status-container-5col { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
    .multi-status-container-5col { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
    .multi-status-container-5col { grid-template-columns: 1fr; }
}

.single-board-wrapper-table {
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    padding: 0.75rem;
    background-color: #fff;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    /* ▼▼▼ [핵심 추가] SVG 오버레이를 위한 기준점 설정 ▼▼▼ */
    position: relative; 
}

.single-board-wrapper-table h6 {
    text-align: center;
    margin-bottom: 0.75rem;
    font-weight: bold;
    color: #333;
}

.status-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 2px;
    table-layout: fixed;
}

.status-table td {
    border: 1px solid #f0f0f0;
    text-align: center;
    vertical-align: middle;
    padding: 3px 1px;
    height: 44px;
    font-size: 0.68rem;
    line-height: 1.15;
    border-radius: 4px;
    color: #444;
}

.status-table .num {
    font-weight: 700;
    font-size: 0.78rem;
    display: block;
    margin-bottom: 1px;
    opacity: 0.75;
}

.status-table .count {
    font-size: 0.85rem;
    font-weight: 700;
}

.status-table .count small {
    font-size: 0.6rem;
    opacity: 0.8;
}

.status-table td.text-white {
    color: white !important;
}
.status-table td.text-white .num,
.status-table td.text-white .count,
.status-table td.text-white small {
    color: white !important;
}

/* ▼▼▼ [핵심 추가] SVG 오버레이 및 라인 스타일 ▼▼▼ */
.svg-overlay-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 0.75rem; /* wrapper와 동일한 패딩 적용 */
    box-sizing: border-box; /* 패딩이 크기에 영향을 주지 않도록 설정 */
    pointer-events: none; /* SVG가 마우스 클릭을 방해하지 않도록 함 */
}

.line-overlay {
    width: 100%;
    height: 100%;
    overflow: visible;
}

.win-path-line {
    stroke: #d9534f; /* 선 색상 (빨간색 계열) */
    stroke-width: 1.5; /* 선 두께 */
    stroke-linecap: round; /* 선 끝을 둥글게 */
    stroke-linejoin: round; /* 선이 꺾이는 부분을 둥글게 */
    fill: none; /* 선 내부를 채우지 않음 */
    filter: drop-shadow(0px 0px 1px rgba(0,0,0,0.5)); /* 선에 약간의 그림자 효과 */
}
/* ▲▲▲ [수정 완료] ▲▲▲ */
/* ========================================================== */
/*  [복구된 기능] 추가된 분석도구 모달 스타일                   */
/* ========================================================== */
.analysis-results-area {
    min-height: 400px;
    max-height: 60vh;
    overflow-y: auto;
    border: 1px solid #e9ecef;
    border-radius: 0.3rem;
    padding: 1rem;
    background-color: #f8f9fa;
    font-size: 0.9rem;
}

.analysis-results-area h6 {
    font-weight: bold;
    color: #343a40;
    margin-bottom: 0.75rem;
    padding-bottom: 0.25rem;
    border-bottom: 1px solid #dee2e6;
}

#coOccurrenceRanksModal table th {
    background-color: #f8f9fa;
    position: sticky;
    top: 0;
}
/* style.css 파일의 맨 아래에 이 코드를 추가하세요. */

/* ========================================================== */
/*  [개선] 통계 모달 창 레이아웃 안정화 (흔들림 방지)        */
/* ========================================================== */
#statisticsModalBody {
    min-height: 500px; /* 로딩 중에도 최소 높이를 유지하여 레이아웃 흔들림 방지 */
}

#statsLoadingIndicator {
    /* 로딩 인디케이터를 수직 중앙에 더 잘 배치하기 위한 스타일 */
    position: relative;
    top: 40%;
    transform: translateY(-50%);
}
/* style.css 파일의 맨 아래에 이 코드를 추가하세요. */

/* ========================================================== */
/*  [개선] 분석 리포트 가이드 수치 강조 스타일                */
/* ========================================================== */
.analysis-guide-value {
    color: #d9534f; /* 눈에 띄는 붉은 계열 색상 */
    font-weight: 700; /* 굵은 글씨 */
    font-size: 1.05em; /* 약간 더 큰 글씨 */
    padding: 0 2px;
}
/* style.css 파일의 맨 아래에 이 코드를 추가하세요. */

/* ========================================================== */
/*  [개선] 통계 그래프 컨테이너 스타일 (레이아웃 안정화)     */
/* ========================================================== */
.chart-container {
    min-height: 350px; /* 각 차트가 그려질 공간을 미리 확보 */
    padding: 1rem;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    background-color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
}
/* --- 로딩 오버레이 개선 --- */
.loading-overlay {
    flex-direction: column; /* 세로로 쌓기 */
}

#loadingStatusText {
    margin-top: 1rem; /* 스피너와의 상단 간격 추가 */
}

/* 
  ==================================================================
  [수정] 1단계 결과창 - 가로 스크롤 방식 제거, 가운데 정렬 + 자동 줄바꿈으로 통일
  (dashboard.html의 공용 .combo-item/.combo-main 스타일을 그대로 따르도록 함)
  ==================================================================
*/
#top-combinations-list,
#all-combinations-list {
    overflow-x: visible;
}
/* 
  ==================================================================
  [신규 추가] 사용자 대시보드 공지사항 바 스타일
  ==================================================================
*/
.announcement-bar {
    background-color: #f0f8ff; /* 연한 하늘색 배경 */
    border-bottom: 1px solid #cce5ff; /* 파란색 계열 테두리 */
    padding: 8px 0;
    width: 100%;
    overflow: hidden; /* 영역을 벗어나는 텍스트를 숨김 */
    white-space: nowrap; /* 텍스트가 줄바꿈되지 않도록 설정 */
    box-sizing: border-box;
}

.announcement-bar p {
    margin: 0;
    padding-left: 100%; /* 화면 오른쪽 끝에서 시작하도록 설정 */
    display: inline-block;
    color: #004085; /* 짙은 파란색 글씨 */
    font-weight: bold;
    font-size: 1rem;
    /* 애니메이션 설정: 20초 동안 'scroll-left' 애니메이션을 선형으로 무한 반복 */
    animation: scroll-left 20s linear infinite;
}

/* 텍스트가 왼쪽으로 흐르는 애니메이션 정의 */
@keyframes scroll-left {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-100%);
    }
}
/* 
  ==================================================================
  [신규 추가] 상세 패턴 정보 - 온도 표시 색상 적용
  ==================================================================
*/

/* Hot(H) 상태의 번호는 굵은 빨간색으로 표시 */
.pattern-value .temp-hot {
    color: #dc3545; /* Bootstrap의 danger 색상 (빨강) */
    font-weight: bold;
}

/* Cold(C) 상태의 번호는 굵은 파란색으로 표시 */
.pattern-value .temp-cold {
    color: #0d6efd; /* Bootstrap의 primary 색상 (파랑) */
    font-weight: bold;
}

/* Normal(N) 상태의 번호는 기본 검정색으로 표시 */
.pattern-value .temp-normal {
    color: #212529; /* Bootstrap의 기본 body 색상 (검정) */
}
/* ========================================================== */
/*  [신규 추가] 오늘의 인기 꿈 키워드 섹션 스타일             */
/* ========================================================== */
.popular-dream-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    border-bottom: 1px dashed #eee;
    background-color: #f8f9fa;
    border-radius: 4px;
    margin-bottom: 4px;
}
.popular-dream-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
}
.popular-dream-keyword {
    font-weight: bold;
    color: #495057;
}
.popular-dream-numbers .lotto-ball-sm {
    margin-left: 3px;
    /* lotto-ball-sm 스타일이 없는 경우 추가 (있는 경우 생략) */
    /* width: 28px; height: 28px; font-size: 0.9rem; */
}

/* ========================================================== */
/* [신규 추가] AI 로또 매니저 모달 내부 포트폴리오 표시 스타일 */
/* ========================================================== */
#ai-manager-modal-body ul.list-group {
    max-height: 300px; /* 스크롤바가 생길 높이 지정 */
    overflow-y: auto; /* 내용이 넘칠 때 세로 스크롤바 생성 */
    border: 1px solid #e9ecef; /* 테두리 추가 */
    border-radius: 0.3rem; /* 모서리 둥글게 */
}
#ai-manager-modal-body .list-group-item {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding: 0.5rem 0.75rem;
    gap: 5px;
    background-color: #fff; /* 배경색 */
    border-bottom: 1px solid #f0f2f5; /* 구분선 */
}
#ai-manager-modal-body .list-group-item:last-child {
    border-bottom: none;
}
/* ========================================================== */
/*  [신규] 프리미엄 부가기능 버튼 스타일                     */
/* ========================================================== */
.nav-link-premium {
    background: linear-gradient(145deg, #6a5acd, #483d8b); /* 세련된 보라색 그라데이션 */
    color: #fff !important; /* 글자색 흰색으로 강제 */
    font-weight: 500;
    border-radius: 5px;
    padding-left: 0.8rem !important;
    padding-right: 0.8rem !important;
    margin: 5px 0;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
    animation: pulse-premium 3s infinite; /* 반짝이는 애니메이션 */
}

.nav-link-premium:hover {
    transform: translateY(-2px); /* 마우스 오버 시 살짝 위로 이동 */
    box-shadow: 0 4px 10px rgba(72, 61, 139, 0.4);
}

/* 프리미엄 버튼 반짝임 애니메이션 */
@keyframes pulse-premium {
    0% {
        box-shadow: 0 0 4px rgba(106, 90, 205, 0.3);
    }
    50% {
        box-shadow: 0 0 12px rgba(106, 90, 205, 0.7);
    }
    100% {
        box-shadow: 0 0 4px rgba(106, 90, 205, 0.3);
    }
}
/* ========================================================== */
/*  [신규] 사주팔자 결과 표시 스타일                         */
/* ========================================================== */
.ganji-grid {
    display: flex;
    justify-content: space-around;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    padding: 1rem;
}
.ganji-col {
    text-align: center;
}
.ganji-title {
    font-size: 0.8rem;
    color: #6c757d;
    margin-bottom: 0.5rem;
}
.ganji-cell {
    font-family: 'Malgun Gothic', '맑은 고딕', sans-serif;
    font-size: 1.8rem;
    font-weight: bold;
    line-height: 1.2;
}
.ganji-cheon {
    color: #0d6efd; /* 천간 색상 */
}
.ganji-ji {
    color: #dc3545; /* 지지 색상 */
}

.daeun-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.5rem;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    padding: 1rem;
}
.daeun-item {
    text-align: center;
    font-family: 'Malgun Gothic', '맑은 고딕', sans-serif;
}
.daeun-age {
    font-size: 0.8rem;
    color: #6c757d;
    background-color: #e9ecef;
    padding: 2px;
    border-radius: 0.25rem;
}
.daeun-ganji {
    font-size: 1.2rem;
    font-weight: bold;
    margin-top: 0.25rem;
}
/* ========================================================== */
/*  [업그레이드] 사주 명반(命盤) 전문가용 스타일             */
/* ========================================================== */
.myeongpan-grid {
    display: flex;
    justify-content: space-around;
    background-color: #fff;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    padding: 1rem;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}
.myeongpan-col {
    text-align: center;
    font-family: 'Malgun Gothic', '맑은 고딕', sans-serif;
}
.myeongpan-header {
    font-size: 0.8rem;
    color: #6c757d;
    margin-bottom: 0.75rem;
}
.myeongpan-cell {
    margin-bottom: 0.5rem;
    min-width: 60px;
}
.myeongpan-cell .sibseong {
    font-size: 0.75rem;
    color: #495057;
}
.myeongpan-cell .cheon, .myeongpan-cell .jiji {
    font-size: 2.2rem;
    font-weight: bold;
    line-height: 1;
}
.myeongpan-cell.jijanggan {
    border-top: 1px solid #e9ecef;
    padding-top: 0.5rem;
    display: flex;
    justify-content: center;
    gap: 4px;
}
.jijanggan-item .cheon {
    font-size: 1.1rem;
}

/* 오행 색상 스타일 */
.ohang-wood { background-color: #e7f5ff; color: #1c7ed6; }
.ohang-fire { background-color: #fff0f6; color: #d6336c; }
.ohang-earth { background-color: #fff9db; color: #f59f00; }
.ohang-metal { background-color: #f8f9fa; color: #495057; }
.ohang-water { background-color: #f3f0ff; color: #7048e8; }
.ohang-wood-text { color: #1c7ed6; }
.ohang-fire-text { color: #d6336c; }
.ohang-earth-text { color: #f59f00; }
.ohang-metal-text { color: #495057; }
.ohang-water-text { color: #7048e8; }

.ohaeng-grid {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    background-color: #fff;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    padding: 1rem;
}
.ohaeng-bar-item {
    display: flex;
    align-items: center;
}
.ohaeng-label {
    width: 30px;
    font-weight: bold;
    text-align: center;
}
.ohaeng-grid .progress {
    flex-grow: 1;
}
.ohaeng-grid .progress-bar {
    font-weight: bold;
    color: #212529;
    text-shadow: 0 0 2px #fff;
}
/* ========================================================== */
/*  [업그레이드] 사주 명반(命盤) 오행 색상 스타일             */
/* ========================================================== */
/* 글자 색상 */
.ohang-wood-text { color: #28a745; } /* 초록 */
.ohang-fire-text { color: #dc3545; } /* 빨강 */
.ohang-earth-text { color: #ffc107; } /* 노랑 */
.ohang-metal-text { color: #6c757d; } /* 회색 */
.ohang-water-text { color: #0d6efd; } /* 파랑 */

/* 배경 색상 (프로그레스 바) */
.bg-wood { background-color: #28a745 !important; }
.bg-fire { background-color: #dc3545 !important; }
.bg-earth { background-color: #ffc107 !important; }
.bg-metal { background-color: #6c757d !important; }
.bg-water { background-color: #0d6efd !important; }

/* 프로그레스 바 내부 텍스트 색상 */
.progress-bar { color: #fff; text-shadow: 1px 1px 1px rgba(0,0,0,0.4); }
.bg-earth { color: #212529; } /* 노란 배경에는 검은 글씨 */

/* 지장간 표시 개선 */
.myeongpan-cell.jijanggan {
    background-color: #f8f9fa;
    border-radius: 4px;
    padding: 0.25rem;
}
/* ========================================================== */
/*  [신규] 사주 해석 아코디언 스타일                       */
/* ========================================================== */
.accordion-button {
    font-size: 0.9rem;
    font-weight: bold;
    padding: 0.75rem 1rem;
}
.accordion-button:not(.collapsed) {
    background-color: #e7f1ff;
    color: #0d6efd;
}
.accordion-body {
    background-color: #f8f9fa;
}
/* ========================================================== */
/*  [업그레이드] 대운 표시 및 해석 모달 스타일              */
/* ========================================================== */
.daeun-ganji-btn {
    font-size: 1.2rem;
    font-weight: bold;
    font-family: 'Malgun Gothic', '맑은 고딕', sans-serif;
    width: 100%;
    padding: 0.5rem 0.2rem;
    border-color: #e9ecef;
    transition: all 0.2s ease-in-out;
}
.daeun-ganji-btn:hover {
    background-color: #0d6efd;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}
.daeun-interp-section {
    background-color: #f8f9fa;
    border-radius: 0.5rem;
    padding: 1rem;
    border: 1px solid #dee2e6;
}
.daeun-interp-section h5 {
    font-weight: 700;
}
.daeun-interp-section h6 {
    font-weight: 600;
    margin-top: 1rem;
}
/* ========================================================== */
/*  [반응형 수정] 네비게이션 바 메뉴 간격 자동 조절 (수정)   */
/* ========================================================== */

/* xl 사이즈(1200px) 이상일 때 기본 여백을 살짝 줄여 공간 확보 */
@media (min-width: 1200px) {
    .navbar-expand-xl .navbar-nav .nav-link {
        padding-right: 0.8rem;
        padding-left: 0.8rem;
    }
}

/* lg 사이즈(992px) ~ xl 사이즈(1200px) 사이에서 여백과 폰트 크기 조정 */
@media (max-width: 1199.98px) {
    .navbar-expand-xl .navbar-nav .nav-link {
        padding-right: 0.5rem;
        padding-left: 0.5rem;
        font-size: 0.9rem; /* 글자 크기 줄임 */
    }
    
    /* 오른쪽 사용자 정보 영역의 버튼들도 여백과 크기를 줄입니다. */
    .navbar-nav.d-none.d-xl-flex .btn-sm {
        padding: 0.2rem 0.4rem;
        font-size: 0.8rem;
    }
    .navbar-nav.d-none.d-xl-flex .navbar-text {
        font-size: 0.85rem; /* 서버 시간 폰트 크기 줄임 */
    }
}

/* md 사이즈(768px) ~ lg 사이즈(992px) 사이에서 더 작은 스타일 적용 (메뉴가 거의 꽉 찰 때) */
@media (max-width: 991.98px) {
     .navbar-expand-lg .navbar-nav .nav-link {
        padding-right: 0.4rem;
        padding-left: 0.4rem;
        font-size: 0.85rem;
    }
}

/* 조합번호 정밀 분석 - 통일된 반응형 격자 카드 (좌측 쏠림 현상 해결) */
.stat-tile-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
    gap: 0.6rem;
}
.stat-tile-grid-lg {
    grid-template-columns: repeat(2, 1fr);
}
.stat-tile-grid-2 {
    grid-template-columns: repeat(2, 1fr);
}
@media (min-width: 768px) {
    .stat-tile-grid-lg {
        grid-template-columns: repeat(4, 1fr);
    }
}