* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: 'Inter', sans-serif;
    overflow: hidden;
    height: 100vh;
    width: 100vw;
    background: radial-gradient(circle at 20% 30%, #071B2F, #010A15);
    color: #E2E8F0;
}
/* 顶部标题栏 */
.dashboard-header {
    position: relative; z-index: 10; display: flex; align-items: center;
    justify-content: space-between; padding: 16px 32px;
    background: rgba(8, 22, 40, 0.5); backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(0, 200, 255, 0.3);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}
.header-left { display: flex; align-items: center; gap: 16px; }
.header-ship-icon { font-size: 2.4rem; color: #00E0FF; text-shadow: 0 0 20px #00a6ff; animation: floatShipIcon 4s infinite ease-in-out; }
@keyframes floatShipIcon { 0%,100%{transform:translateY(0) rotate(0deg);} 50%{transform:translateY(-6px) rotate(3deg);} }
.system-title {
    font-size: 1.8rem; font-weight: 700;
    background: linear-gradient(135deg, #FFFFFF, #A0D0FF);
    background-clip: text; -webkit-background-clip: text; color: transparent;
    letter-spacing: 2px; text-shadow: 0 0 30px rgba(0,160,255,0.5);
}
.header-right {
    display: flex;
    align-items: center;
    gap: 24px;
}
.clock-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
    background: rgba(0,20,35,0.5);
    backdrop-filter: blur(8px);
    padding: 6px 20px 6px 12px;
    border-radius: 60px;
    border: 1px solid rgba(0,224,255,0.4);
}
#analogClock {
    width: 52px;
    height: 52px;
    display: block;
    filter: drop-shadow(0 0 8px #00aaff66);
}
.live-clock {
    color: #E0F0FF;
    font-weight: 600;
    font-size: 1.1rem;
    letter-spacing: 1px;
}
.live-clock i {
    margin-right: 6px;
    color: #00E0FF;
}
/* 背景特效 */
.star-field { position: fixed; top:0; left:0; width:100%; height:100%; z-index:0; pointer-events: none; }
.star { position: absolute; background: rgba(255,255,255,0.7); border-radius: 50%; box-shadow:0 0 8px #00d9ff; animation:twinkle 4s infinite alternate; }
@keyframes twinkle { 0%{opacity:0.1; transform:scale(0.8);} 100%{opacity:0.8; transform:scale(1.2);} }
.ocean-bg { position: fixed; top:0; left:0; width:100%; height:100%; z-index:0; overflow:hidden; }
.ocean-bg::before { content:""; position:absolute; width:200%; height:200%; background:radial-gradient(circle at 30% 40%, rgba(0,150,255,0.1), transparent 60%); animation:slowDrift 30s infinite alternate; }
.wave { position:absolute; bottom:0; left:0; width:100%; height:15%; background:repeating-linear-gradient(transparent 0px, transparent 38px, rgba(0,230,255,0.25) 38px, rgba(0,200,240,0.4) 52px); animation:waveMove 12s infinite linear; pointer-events:none; }
.wave2 { bottom:6%; height:18%; opacity:0.6; animation-duration:18s; background-position-y:10px; }
.wave3 { bottom:-2%; height:25%; opacity:0.35; animation-duration:24s; }
@keyframes waveMove { 0%{background-position-x:0px;} 100%{background-position-x:280px;} }
@keyframes slowDrift { 0%{transform:translate(0%,0%) rotate(0deg);} 100%{transform:translate(-5%,-5%) rotate(2deg);} }
.floating-ship { position:absolute; bottom:12%; right:6%; font-size:90px; opacity:0.3; animation:floatShip 16s infinite ease-in-out; pointer-events:none; filter:drop-shadow(0 10px 15px rgba(0,0,0,0.3)); }
@keyframes floatShip { 0%{transform:translateX(0px) translateY(0px) rotate(0deg);} 50%{transform:translateX(-40px) translateY(-12px) rotate(2deg);} 100%{transform:translateX(0px) translateY(0px) rotate(0deg);} }
/* 主布局 */
.dashboard {
    position: relative; z-index: 2; display: grid;
    grid-template-columns: 300px 360px 1fr; gap: 24px;
    height: calc(100vh - 80px); padding: 20px 28px;
    backdrop-filter: blur(3px); overflow: hidden;
}
/* 卡片样式 */
.card {
    background: rgba(8,22,40,0.65); backdrop-filter: blur(20px);
    border-radius: 38px; border: 1px solid rgba(0,200,255,0.3);
    box-shadow: 0 25px 40px -12px rgba(0,0,0,0.5), inset 0 1px 0 rgba(255,255,255,0.05);
    overflow-y: auto; scrollbar-width: none; padding: 22px 18px;
    transition: all 0.3s cubic-bezier(0.2,0.9,0.4,1);
    animation: cardFadeIn 0.6s ease-out forwards; opacity:0; transform:translateY(20px);
}
.card:nth-child(1) { animation-delay:0.1s; }
.card:nth-child(2) { animation-delay:0.2s; }
.card:nth-child(3) { animation-delay:0.3s; }
@keyframes cardFadeIn { to { opacity:1; transform:translateY(0); } }
.card::-webkit-scrollbar { display:none; }
.card:hover { border-color: rgba(0,224,255,0.7); box-shadow:0 30px 50px -12px rgba(0,180,255,0.3), inset 0 1px 0 rgba(255,255,255,0.1); }
.card-header {
    font-size: 1.5rem; font-weight: 700;
    background: linear-gradient(135deg, #FFFFFF, #B0E0FF);
    background-clip: text; -webkit-background-clip: text; color: transparent;
    padding-left: 18px; margin-bottom:24px;
    display: flex; align-items: center; gap:12px;
}
.card-header i { color:#00E0FF; font-size:1.6rem; text-shadow:0 0 12px #00a6ff; animation:iconPulse 3s infinite; }
@keyframes iconPulse { 0%,100%{opacity:0.9; text-shadow:0 0 8px #00a6ff;} 50%{opacity:1; text-shadow:0 0 18px #00e0ff;} }
/* 表格 */
.param-table { width:100%; font-size:0.8rem; border-collapse:separate; border-spacing:0 12px; }
.param-table th { text-align:center; font-weight:600; color:#B0D4FF; padding-bottom:12px; font-size:0.75rem; border-bottom:2px solid rgba(0,200,255,0.3); text-transform:uppercase; }
.param-table td { padding:12px 4px; background:rgba(10,25,45,0.5); backdrop-filter:blur(4px); text-align:center; transition:all 0.2s; }
.param-table tr td:first-child { border-radius:20px 0 0 20px; padding-left:12px; }
.param-table tr td:last-child { border-radius:0 20px 20px 0; padding-right:12px; }
.param-table tr:hover td { background:rgba(20,40,65,0.7); box-shadow:0 4px 12px rgba(0,150,255,0.2); }
.berth-id-badge { display:flex; align-items:center; justify-content:center; gap:6px; font-weight:700; font-size:1rem; color:#E0F0FF; }
.berth-id-badge i { color:#00E0FF; font-size:1rem; text-shadow:0 0 6px #00a6ff; }
.berth-type-tag { font-size:0.6rem; background:#0F2B3F; padding:2px 8px; border-radius:20px; margin-left:6px; color:#AAD4FF; }
.param-table input { width:80px; background:rgba(0,15,30,0.8); border:1px solid #2C9CD4; border-radius:24px; padding:8px 4px; color:white; text-align:center; font-weight:600; font-size:0.8rem; }
.param-table input:focus { outline:none; border-color:#00E0FF; box-shadow:0 0 12px #00a6ff, inset 0 0 4px #00a6ff; background:rgba(0,25,50,0.9); }
/* 按钮 */
.btn-secondary { background:rgba(0,100,180,0.6); border:1px solid #00C2FF; border-radius:44px; padding:8px 16px; font-weight:600; color:white; width:100%; margin-top:12px; cursor:pointer; transition:0.2s; }
.btn-secondary:hover { background:#0066CC; transform:translateY(-2px); box-shadow:0 6px 14px rgba(0,100,255,0.3); }
.btn-primary { background:linear-gradient(95deg, #0066FF, #00C2FF); border:none; border-radius:44px; padding:12px 20px; font-weight:700; color:white; width:100%; margin-top:16px; cursor:pointer; transition:0.25s; box-shadow:0 8px 18px rgba(0,100,255,0.3); position:relative; overflow:hidden; }
.btn-primary::after { content:''; position:absolute; top:0; left:-100%; width:100%; height:100%; background:linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent); transition:left 0.5s; }
.btn-primary:hover::after { left:100%; }
.btn-primary:hover { transform:translateY(-3px); filter:brightness(1.05); box-shadow:0 14px 24px -8px #0066ff; }
/* 船舶列表 */
.ship-list { max-height:300px; overflow-y:auto; scrollbar-width:none; }
.ship-list::-webkit-scrollbar { display:none; }
.ship-item { background:rgba(12,30,48,0.8); backdrop-filter:blur(6px); margin:12px 0; padding:12px 16px; border-radius:30px; display:flex; justify-content:space-between; align-items:center; font-size:0.8rem; border-left:5px solid #2C9CD4; transition:0.2s; }
.ship-item:hover { background:rgba(18,40,60,0.9); border-left-color:#00E0FF; }
.badge-priority { background:#0F2B3F; border-radius:40px; padding:4px 14px; font-size:0.7rem; font-weight:600; }
.btn-icon { background:rgba(255,70,70,0.2); border:none; color:#FFB4A2; cursor:pointer; border-radius:30px; padding:6px 10px; transition:0.2s; }
.btn-icon:hover { background:#ff4d4d; color:white; transform:scale(1.05); }
.input-group { display:flex; gap:10px; flex-wrap:wrap; margin-bottom:18px; }
.input-group input, .input-group select { background:rgba(0,20,35,0.9); border:1px solid #2C6E9E; border-radius:30px; padding:10px 14px; color:#F0F9FF; font-size:0.8rem; }
.stats-cards { display:flex; gap:14px; margin-bottom:24px; }
.stat { background:rgba(0,20,35,0.7); backdrop-filter:blur(8px); border-radius:30px; padding:16px 8px; text-align:center; flex:1; border:1px solid rgba(0,200,255,0.4); }
.stat i { font-size:1.8rem; color:#00E0FF; margin-bottom:8px; display:block; }
.stat span { font-size:1.9rem; font-weight:800; display:block; color:white; text-shadow:0 0 10px #00a6ff; }
.gantt-container { background:rgba(0,0,0,0.4); border-radius:30px; padding:18px; overflow-x:auto; margin:10px 0; }
.berth-row { margin-bottom:22px; background:rgba(10,25,45,0.6); border-radius:28px; padding:14px; }
.timeline-bar { display:flex; align-items:center; gap:12px; flex-wrap:wrap; margin-top:12px; }
.bar-segment { background:linear-gradient(90deg, #2b95d6, #00b4ff); height:44px; border-radius:30px; display:inline-flex; align-items:center; padding:0 16px; color:white; font-weight:700; font-size:0.75rem; white-space:nowrap; box-shadow:0 4px 12px rgba(0,0,0,0.4), 0 0 10px #00b4ff80; transition:transform 0.15s; }
.bar-segment:hover { transform:scaleY(1.08); background:linear-gradient(90deg, #3aa2e0, #1ec8ff); }
hr { border-color:rgba(0,150,255,0.3); margin:10px 0; }
.allocation-table-wrapper { max-height:210px; overflow-y:auto; margin-top:14px; border-radius:26px; }
.result-table { width:100%; font-size:0.75rem; border-collapse:collapse; }
.result-table th, .result-table td { padding:10px 6px; border-bottom:1px solid #2c5575; text-align:left; }
.result-table th { color:#8ecaff; }
.charts-row { display:flex; gap:20px; margin:20px 0 16px; flex-wrap:wrap; }
.chart-box { flex:1; background:rgba(0,20,35,0.5); backdrop-filter:blur(8px); border-radius:28px; padding:12px; border:1px solid rgba(0,200,255,0.2); }
.chart-box h4 { text-align:center; margin-bottom:10px; font-size:0.9rem; color:#b8e2ff; }
canvas { max-height:220px; width:100%; }
.modal-overlay { position:fixed; top:0; left:0; width:100%; height:100%; background:rgba(0,0,0,0.7); backdrop-filter:blur(10px); z-index:1000; display:flex; align-items:center; justify-content:center; visibility:hidden; opacity:0; transition:0.3s; }
.modal-overlay.active { visibility:visible; opacity:1; }
.modal-container { background:rgba(8,22,40,0.95); backdrop-filter:blur(20px); border-radius:48px; border:1px solid #00E0FF; width:80%; max-width:1000px; max-height:85vh; overflow-y:auto; padding:28px; box-shadow:0 30px 50px rgba(0,0,0,0.5); }
.modal-container h2 { color:#00E0FF; margin-bottom:20px; display:flex; gap:12px; align-items:center; }
.modal-table { width:100%; border-collapse:collapse; margin-bottom:20px; }
.modal-table th, .modal-table td { padding:12px 8px; border-bottom:1px solid #2c6e9e; text-align:center; }
.modal-table input { background:#0a1e30; border:1px solid #2C9CD4; border-radius:20px; padding:8px; color:white; width:100%; text-align:center; }
.modal-actions { display:flex; gap:16px; justify-content:flex-end; }
.btn-modal { padding:10px 24px; border-radius:40px; border:none; font-weight:600; cursor:pointer; }
.btn-save { background:linear-gradient(95deg, #0066FF, #00C2FF); color:white; }
.btn-cancel { background:rgba(100,100,130,0.6); color:#eee; }
.add-row-btn { background:#1e5a7a; border:none; padding:8px 20px; border-radius:40px; color:white; margin-right:12px; cursor:pointer; }
.modal-footer-toolbar { display:flex; align-items:center; margin-bottom:20px; }
.toast-message { position:fixed; bottom:30px; left:50%; transform:translateX(-50%); background:rgba(0,0,0,0.8); backdrop-filter:blur(10px); color:#00e0ff; padding:12px 24px; border-radius:40px; font-size:0.9rem; z-index:2000; border-left:4px solid #00e0ff; box-shadow:0 4px 15px rgba(0,0,0,0.3); animation:fadeOut 3s forwards; pointer-events:none; }
@keyframes fadeOut { 0%{opacity:1; bottom:30px;} 70%{opacity:1;} 100%{opacity:0; bottom:0; visibility:hidden;} }

/* 左侧小组件样式*/
.widgets-panel {
    margin-top: 20px;
    border-top: 1px dashed rgba(0,200,255,0.25);
    padding-top: 16px;
}
.mini-stats {
    display: flex;
    gap: 12px;
    justify-content: space-between;
    margin: 8px 0 12px;
    flex-wrap: wrap;
}
.mini-stat-item {
    background: rgba(0,20,35,0.5);
    backdrop-filter: blur(8px);
    border-radius: 24px;
    padding: 8px 4px;
    text-align: center;
    flex: 1;
    min-width: 60px;
    border: 1px solid rgba(0,200,255,0.3);
    transition: 0.2s;
}
.mini-stat-item:hover {
    background: rgba(0,40,60,0.7);
    border-color: #00e0ff;
    transform: translateY(-2px);
}
.mini-stat-item i {
    font-size: 1.2rem;
    color: #00e0ff;
    display: block;
    margin-bottom: 6px;
}
.mini-stat-item span {
    font-size: 1.2rem;
    font-weight: 700;
    display: block;
    color: white;
    line-height: 1.3;
}
.mini-stat-item small {
    font-size: 0.6rem;
    color: #b0d4ff;
    letter-spacing: 0.5px;
}
.tide-info, .load-factor {
    background: rgba(0,20,35,0.4);
    border-radius: 24px;
    padding: 10px 14px;
    margin: 12px 0 6px;
    font-size: 0.75rem;
    border: 1px solid rgba(0,200,255,0.2);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}
.load-factor {
    flex-direction: column;
    align-items: stretch;
}
#loadFactorBar {
    transition: width 0.3s ease;
}