/* 
   ==========================================================================
   AI 身心管理系統 - 專業高級感設計系統 (Style System v2.0)
   ========================================================================== 
*/

/* 引入優雅字體 */
body {
    font-family: 'Outfit', 'Noto Sans TC', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: #FAF8F5;
    color: #3E3832;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 現代柔和漸層背景 */
.bg-ambient {
    background: radial-gradient(circle at 10% 20%, rgba(217, 155, 78, 0.04) 0%, rgba(250, 248, 245, 0) 50%),
                radial-gradient(circle at 90% 80%, rgba(201, 122, 117, 0.06) 0%, rgba(250, 248, 245, 0) 50%),
                radial-gradient(circle at 50% 50%, rgba(96, 163, 141, 0.04) 0%, rgba(250, 248, 245, 0) 100%);
    background-attachment: fixed;
}

/* 專業毛玻璃效果 (Premium Glassmorphism) */
.glass-warm { 
    background: rgba(255, 255, 255, 0.82); 
    backdrop-filter: blur(20px); 
    -webkit-backdrop-filter: blur(20px); 
    border: 1px solid rgba(234, 228, 220, 0.7); 
    box-shadow: 0 4px 30px rgba(62, 56, 50, 0.03);
}

.glass-card { 
    background: rgba(255, 255, 255, 0.96); 
    backdrop-filter: blur(16px); 
    -webkit-backdrop-filter: blur(16px); 
    border: 1px solid rgba(206, 196, 182, 0.9); /* 明確且較深的暖沙色邊框，區隔明顯 */
    box-shadow: 0 4px 20px rgba(74, 62, 61, 0.06); /* 清晰的暖灰柔和陰影 */
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.glass-card:hover {
    transform: translateY(-4px);
    background: rgba(255, 255, 255, 0.88); 
    border-color: rgba(201, 122, 117, 0.5);
    box-shadow: 0 20px 40px rgba(201, 122, 117, 0.08);
}

.glass-modal { 
    background: rgba(255, 255, 255, 0.96); 
    backdrop-filter: blur(24px); 
    -webkit-backdrop-filter: blur(24px); 
    border: 1px solid rgba(212, 146, 142, 0.25); 
    box-shadow: 0 25px 60px rgba(62, 56, 50, 0.12);
}

/* 狀態脈衝發光陰影 (Pulse Glow Lights) */
.status-glow-green {
    box-shadow: 0 0 10px rgba(118, 191, 166, 0.6);
    animation: pulse-green 2s infinite alternate;
}
.status-glow-yellow {
    box-shadow: 0 0 10px rgba(217, 155, 78, 0.6);
    animation: pulse-yellow 2s infinite alternate;
}
.status-glow-red {
    box-shadow: 0 0 10px rgba(201, 122, 117, 0.6);
    animation: pulse-red 1.5s infinite alternate;
}

@keyframes pulse-green {
    0% { box-shadow: 0 0 6px rgba(118, 191, 166, 0.3); }
    100% { box-shadow: 0 0 14px rgba(118, 191, 166, 0.75); }
}
@keyframes pulse-yellow {
    0% { box-shadow: 0 0 6px rgba(217, 155, 78, 0.3); }
    100% { box-shadow: 0 0 14px rgba(217, 155, 78, 0.75); }
}
@keyframes pulse-red {
    0% { box-shadow: 0 0 6px rgba(201, 122, 117, 0.3); }
    100% { box-shadow: 0 0 16px rgba(201, 122, 117, 0.9); }
}

/* 高級數據表格樣式 */
.premium-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}
.premium-table th {
    font-weight: 700;
    color: #7E766C;
    border-bottom: 2px solid rgba(234, 228, 220, 0.8);
    padding: 1rem 0.75rem;
}
.premium-table td {
    padding: 1.1rem 0.75rem;
    border-bottom: 1px solid rgba(234, 228, 220, 0.5);
    transition: background-color 0.2s;
}
.premium-table tbody tr:hover td {
    background-color: rgba(234, 228, 220, 0.15);
}

/* 側邊欄導覽項目動態 */
.sidebar-link {
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
}
.sidebar-link::before {
    content: '';
    position: absolute;
    left: 0;
    top: 25%;
    height: 50%;
    width: 3px;
    background-color: #C97A75;
    border-radius: 0 4px 4px 0;
    transform: scaleX(0);
    transition: transform 0.25s;
}
.sidebar-link:hover {
    padding-left: 1.25rem;
    background-color: rgba(234, 228, 220, 0.3);
    color: #3E3832;
}
.sidebar-link:hover::before {
    transform: scaleX(1);
}

/* 科技波紋動畫 (針對語音錄音與 AI 處理) */
.ripple-button {
    position: relative;
    z-index: 1;
}
.ripple-button::after {
    content: '';
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    border: 2px solid rgba(37, 99, 235, 0.4);
    opacity: 0;
    animation: ripple 2s infinite ease-out;
    pointer-events: none;
    z-index: -1;
}
.ripple-button-active::after {
    opacity: 1;
}

@keyframes ripple {
    0% { transform: scale(0.9); opacity: 0.9; }
    100% { transform: scale(1.3); opacity: 0; }
}

/* 客製化滾動條 */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: #FAF8F5;
}
::-webkit-scrollbar-thumb {
    background: #C97A75;
    border-radius: 10px;
    opacity: 0.5;
}
::-webkit-scrollbar-thumb:hover {
    background: #9C8BB5;
}

/* 數值進度條 */
.drive-progress-bar {
    height: 6px;
    border-radius: 10px;
    background: #EAE4DC;
    position: relative;
    overflow: hidden;
}
.drive-progress-fill {
    height: 100%;
    border-radius: 10px;
    transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

/* 計畫案專用 Q-Value 運算節點卡片樣式 */
.qvalue-badge {
    background: linear-gradient(135deg, rgba(118, 191, 166, 0.1) 0%, rgba(181, 156, 212, 0.1) 100%);
    border: 1px solid rgba(99, 102, 241, 0.25);
}
.formula-card {
    background: linear-gradient(to bottom right, #FFFFFF, rgba(250, 248, 245, 0.6));
    border: 1.5px dashed rgba(37, 99, 235, 0.4);
}
