#toolbar {
    position: fixed;
    bottom: 40px; 
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 40px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    padding: 8px 16px;
    z-index: 2000; 
    white-space: nowrap;
    text-align: center;
    box-sizing: border-box;
    transition: bottom 0.3s ease-out, left 0.3s ease-out;
}

#toolbar > div {
    display: inline-block;
    vertical-align: middle;
}

#toggle-wrapper {
    cursor: pointer;
    padding-right: 10px;
}

#mode-label {
    font-size: 14px;
    margin-right: 8px;
    display: inline-block;
    vertical-align: middle;
    font-family: sans-serif;
    color: #333;
    font-weight: bold;
}

.switch {
    width: 36px;
    height: 20px;
    background-color: #ccc;
    border-radius: 10px;
    position: relative;
    display: inline-block;
    vertical-align: middle;
    transition: background-color 0.3s;
}

.switch.on {
    background-color: #eb7b3b;
}

.switch-knob {
    width: 16px;
    height: 16px;
    background-color: #fff;
    border-radius: 50%;
    position: absolute;
    top: 2px;
    left: 2px;
    transition: left 0.3s;
}

.switch.on .switch-knob {
    left: 18px;
}

.separator {
    width: 1px;
    height: 24px;
    background-color: #e0e0e0;
    margin: 0 10px;
}

.tool-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: #f5f5f5;
    margin: 0 4px;
    cursor: pointer;
    text-align: center;
    line-height: 36px;
}

.tool-btn svg {
    vertical-align: middle;
    margin-top: -4px;
}

.tool-btn.active {
    background-color: #f4dccb;
    color: #eb7b3b;
}

.tool-btn.disabled {
    opacity: 0.4;
    cursor: not-allowed;
    background-color: #f5f5f5;
    color: #999;
}

#list-toggle-btn {
    position: absolute;
    z-index: 1000;
    background: #2874A6;
    color: #FFFFFF;
    border: none;
    border-radius: 15px;
    padding: 8px 16px;
    font-weight: bold;
    font-size: 13px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    cursor: pointer;
    transition: left 0.3s ease;
}

#list-toggle-btn:hover {
    background: #1A5276;
}

#list-panel-container {
    position: absolute;
    z-index: 1000;
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
    transition: left 0.3s ease, right 0.3s ease;
}

#list-panel {
    width: 100%;
    height: 100%;
    overflow-y: auto;
    padding: 12px;
    box-sizing: border-box;
}

.list-row {
    display: block;
    margin-bottom: 10px;
    clear: both;
    overflow: hidden;
    border-bottom: 1px solid #EEEEEE;
    padding-bottom: 6px;
}

.list-row:last-child {
    margin-bottom: 0;
    border-bottom: none;
    padding-bottom: 0;
}

.list-marker {
    float: left;
}

.list-data {
    float: right;
    line-height: 28px;
    font-weight: bold;
    color: #333;
    font-size: 14px;
}

.list-alt {
    color: #7f8c8d;
    font-size: 13px;
    margin-right: 6px;
}

#stats-panel {
    position: absolute;
    bottom: 10px;
    left: 10px;
    width: calc(100% - 20px);
    border-radius: 16px;
    background-color: #FFF;
    padding: 10px 20px 10px 20px;
    box-sizing: border-box;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
    z-index: 1000;
    font-family: sans-serif;
    color: #000000;
}

#panel-drag-handle {
    width: 100%;
    height: 24px;
    cursor: ns-resize;
    margin-top: -5px;
    margin-bottom: 5px;
    text-align: center;
}

.handle-line {
    width: 40px;
    height: 4px;
    background-color: #c0c0c0;
    border-radius: 2px;
    margin: 0 auto;
}

#stats-extra {
    height: 0;
    overflow: hidden;
}

.stats-row {
    width: 100%;
    margin-bottom: 12px;
}

.border-top {
    border-top: 1px solid #e0e0e0;
    padding-top: 12px;
    margin-top: 8px;
    margin-bottom: 0;
}

.stat-box {
    display: block;
    float: left;
    box-sizing: border-box;
}

.half {
    width: 50%;
}

.third {
    width: 33.33%;
}

.border-left {
    border-left: 1px solid #e0e0e0;
}

.pl-10 { padding-left: 10px; }
.pl-15 { padding-left: 15px; }
.pr-5 { padding-right: 5px; }

.stat-label {
    display: block;
    font-size: 11px;
    color: #4a4a4a;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.stat-val {
    display: block;
    font-weight: bold;
    color: #111111;
}

#stat-ele-neg {
    color: #111111;
}

.stat-val.large {
    font-size: 38px;
    line-height: 1;
}

.stat-val.small {
    font-size: 18px;
    line-height: 1.2;
}

.unit {
    font-size: 0.5em;
    font-weight: normal;
    color: #111111;
}

.clear {
    clear: both;
}

.chart-row {
    width: 100%;
    height: auto;
    margin-bottom: 0;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
    box-sizing: border-box;
}

.elevation-chart {
    width: 100%;
    height: auto;
    display: block;
}

.grid-line {
    stroke: #dbd9cc;
    stroke-width: 1;
    stroke-dasharray: 6 4;
}

.chart-area {
    fill: #c7c5b399;
}

.chart-line {
    fill: none;
    stroke: #4f4d2f;
    stroke-width: 2.5;
}

.point-main {
    fill: #d86c31;
    stroke: #4f4d2f;
    stroke-width: 1.5;
}
