* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body {
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 100%;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 0;
    position: relative;
}

header {
    background-color: #007aff;
    color: white;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 10;
}

header h1 {
    font-size: 18px;
    font-weight: 600;
}

.add-btn {
    background-color: transparent;
    color: white;
    border: 1px solid white;
    border-radius: 4px;
    padding: 6px 12px;
    font-size: 14px;
    cursor: pointer;
}

.points-list {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
}

.point-item {
    background: white;
    border-radius: 8px;
    margin-bottom: 10px;
    padding: 15px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    position: relative;
}

.point-name {
    font-weight: 600;
    margin-bottom: 5px;
}

.point-coords {
    font-size: 14px;
    color: #666;
}

.delete-btn {
    position: absolute;
    right: 15px;
    top: 15px;
    background: transparent;
    color: #ff3b30;
    border: none;
    font-size: 14px;
    cursor: pointer;
}

.footer {
    padding: 15px;
    background: white;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
}

.calibrate-btn {
    background-color: #007aff;
    color: white;
    border: none;
    border-radius: 8px;
    width: 100%;
    padding: 15px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
}

.calibrate-btn:active {
    background-color: #0062cc;
}

/* 模态弹窗 */
.modal {
    display: none;
    position: fixed;
    z-index: 100;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: white;
    margin: 20% auto;
    padding: 20px;
    border-radius: 12px;
    width: 80%;
    max-width: 400px;
    position: relative;
}

.close-modal {
    position: absolute;
    right: 20px;
    top: 15px;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
}

.input-group {
    margin: 20px 0;
}

.input-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

.input-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 16px;
}

.submit-btn {
    background-color: #007aff;
    color: white;
    border: none;
    border-radius: 8px;
    width: 100%;
    padding: 12px;
    font-size: 16px;
    cursor: pointer;
    margin-top: 10px;
}

/* 结果页面 */
.result-page {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: white;
    z-index: 50;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.result-content {
    padding: 20px;
    max-width: 300px;
}

.success-icon, .fail-icon {
    font-size: 60px;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    margin: 0 auto 20px;
}

.success-icon {
    background-color: #4cd964;
    color: white;
}

.fail-icon {
    background-color: #ff3b30;
    color: white;
}

.retry-btn, .back-btn {
    margin-top: 20px;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 16px;
    cursor: pointer;
    display: block;
    width: 100%;
}

.retry-btn {
    background-color: #007aff;
    color: white;
    border: none;
    margin-bottom: 10px;
}

.back-btn {
    background-color: #e5e5ea;
    color: #333;
    border: none;
}

/* Loading spinner and overlay */
.loading-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    color: white;
}

.loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.loading-spinner {
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top: 4px solid #007aff;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin-bottom: 10px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Toast notifications */
.toast {
    visibility: hidden;
    min-width: 250px;
    background-color: rgba(0, 0, 0, 0.8);
    color: #fff;
    text-align: center;
    border-radius: 8px;
    padding: 16px;
    position: fixed;
    z-index: 1001;
    left: 50%;
    bottom: 30px;
    transform: translateX(-50%);
    font-size: 14px;
}

.toast.show {
    visibility: visible;
    animation: fadein 0.5s, fadeout 0.5s 2s;
}

@keyframes fadein {
    from {bottom: 0; opacity: 0;}
    to {bottom: 30px; opacity: 1;}
}

@keyframes fadeout {
    from {bottom: 30px; opacity: 1;}
    to {bottom: 0; opacity: 0;}
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 40px 0;
    color: #999;
}

.empty-state p {
    margin-bottom: 10px;
}

/* No data icon */
.no-data-icon {
    font-size: 40px;
    margin-bottom: 10px;
    color: #ccc;
}

/* 结果数据样式 */
.result-data {
    margin: 20px 0;
    background-color: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    text-align: left;
}

.result-item {
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid #eee;
    padding-bottom: 8px;
}

.result-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.result-label {
    font-weight: 500;
    color: #666;
}

.result-value {
    font-weight: 600;
    color: #333;
} 