.compdiv{
    max-width:20rem;
    width: 100%;
    margin: auto;
    text-align: center;
    border: 1px solid #eee;
    padding: 0.5rem;
    border-radius: 6px;
}

.night .compdiv{
    border: 1px solid #444;
}

.compass-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    border: 1px solid #eee;
    padding: 0.75rem;
    border-radius: 6px;
}

.night .compass-wrap {
    border: 1px solid #444;
}

.marker {
    position: absolute;
    top: 0px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 14px solid #FF5722;
    z-index: 10;
}

#compass-svg {
 
}

.compassfoot{
    width: 100%;
    text-align: center;
    border: 1px solid #eee;
    margin-top: 0.5rem;
    padding: 0.5rem;
    border-radius: 6px;
}

.night .compassfoot{
    border: 1px solid #444;
}

.compass-wrap.calibrating .dial-ring {
    stroke: #00c2ff;
}

.center-dot {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 14px;
    height: 14px;
    margin: -7px 0 0 -7px;
    background: radial-gradient(#ffe97a, #c99700);
    border-radius: 50%;
    z-index: 20;
    box-shadow: 0 0 8px rgba(255, 215, 0, 0.6);
}

.directiondiv{
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    padding: 0 0.5rem;
}

#direction-text {
    font-size: 0.7rem;
}

#degree-text {
    font-size: 0.7rem;
}

#calib-info {
    color: #556677;
    margin-top: 4px;
}

#hint {
    margin-top: 0.6rem;
    padding: 8px 16px;
    border-radius: 3px;
    background: rgba(255, 80, 80, 0.15);
    border: 1px solid rgba(255, 80, 80, 0.4);
    color: #ff9999;
    text-align: center;
}

#hint.detecting {
    background: rgba(0, 194, 255, 0.1);
    border-color: rgba(0, 194, 255, 0.35);
    color: #7fdcff;
}

.btn-row {
    margin-top: 0.5rem;
    display: flex;
    gap: 0.6rem;
}

.btn-row button {
    padding: 0.5rem 0;
    border: none;
    width: 100%;
    border-radius: 3px;
    cursor: pointer;
}

#start-btn {
    background: #00c2ff;
    color: #fff;
}

#calib-btn {
    background: #2a3a55;
    color: #8899aa;
}

#calib-panel {
    margin-top: 0.5rem;
    padding: 0.5rem;
    border-radius: 3px;
    border: 1px solid #eee;
}

.night #calib-panel{
    border: 1px solid #444;
}

#calib-panel .calib-title {
    font-size: 15px;
    font-weight: bold;
    color: #7fdcff;
}

#calib-panel .calib-tip {
    font-size: 0.5rem;
    color: #8899aa;
    margin: 8px 0 8px;
    line-height: 1.6;
}

#calib-panel .calib-value {
    font-size: 0.9rem;
    margin: 6px 0;
}

.night #calib-panel .calib-value {

}

.calibbutdiv{
    display: grid;
    gap: 0.5rem;
    grid-template-columns: repeat(3, 1fr);
    border-top: 1px solid #eee;
    padding-top: 0.5rem;
}

.night .calibbutdiv{
    border-top: 1px solid #444;
}

.calibbutdiv button{
    padding: 0.25rem;
    border: 0;
    border-radius: 3px;
    color: #2a3a55;
    border: 1px solid #eee;
    background-color: #fff;
    cursor: pointer;
}

.night .calibbutdiv button{
    color: #aaa;
    border: 1px solid #444;
    background-color: #181a1b;
}

#calib-confirm {
    background: #00c2ff;
    color: #fff;
    border: 1px solid #00c2ff;
}

.hidden {
    display: none;
}