/* ========================================
   Mega Route Planner Styles
   Complete GPX + Adventure Route System
   ======================================== */

.mega-planner {
    position: fixed;
    top: 60px;
    right: 20px;
    width: 420px;
    max-height: calc(100vh - 80px);
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    z-index: 2000;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.mega-header {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 20px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.mega-header h2 {
    margin: 0;
    font-size: 20px;
}

.mega-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

.mega-step {
    background: #f9fafb;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 16px;
}

.mega-step h3 {
    margin: 0 0 16px 0;
    color: #10b981;
    font-size: 16px;
}

/* Upload Zone */
.upload-zone {
    border: 3px dashed #d1d5db;
    border-radius: 12px;
    padding: 30px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    background: #ffffff;
}

.upload-zone:hover {
    border-color: #10b981;
    background: #f0fdf4;
}

/* Selection Lists */
.selection-list {
    max-height: 300px;
    overflow-y: auto;
}

.selection-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.selection-item:hover {
    border-color: #10b981;
    background: #f0fdf4;
}

.selection-item.selected {
    border-color: #10b981;
    background: #d1fae5;
}

.selection-item input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.item-info {
    flex: 1;
}

.item-info strong {
    color: #10b981;
}

.item-desc {
    font-size: 12px;
    color: #6b7280;
    margin-top: 4px;
}

.item-meta {
    font-size: 11px;
    color: #9ca3af;
    margin-top: 4px;
}

/* Settings */
.settings-row {
    margin-bottom: 16px;
}

.settings-row label {
    display: block;
    font-size: 14px;
}

.settings-row select {
    width: 100%;
    padding: 8px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    margin-top: 6px;
}

/* Transport Selector */
.transport-selector {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.transport-option {
    cursor: pointer;
}

.transport-option input[type="radio"] {
    display: none;
}

.transport-card {
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    padding: 16px;
    text-align: center;
    transition: all 0.2s;
}

.transport-option input:checked + .transport-card {
    border-color: #10b981;
    background: #d1fae5;
}

.transport-card:hover {
    border-color: #10b981;
}

.transport-icon {
    font-size: 32px;
    margin-bottom: 8px;
}

.transport-label {
    font-weight: 600;
    font-size: 13px;
    color: #1f2937;
}

.transport-speed {
    font-size: 11px;
    color: #6b7280;
    margin-top: 4px;
}

/* Route Stats */
.route-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.stat-card {
    background: white;
    border: 2px solid #10b981;
    border-radius: 12px;
    padding: 16px;
    text-align: center;
}

.stat-icon {
    font-size: 24px;
    margin-bottom: 8px;
}

.stat-value {
    font-size: 20px;
    font-weight: 700;
    color: #10b981;
    margin-bottom: 4px;
}

.stat-label {
    font-size: 11px;
    color: #6b7280;
}

/* Route Order */
.route-order {
    background: white;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
    max-height: 300px;
    overflow-y: auto;
}

.route-step {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-bottom: 1px solid #f3f4f6;
}

.route-step:last-child {
    border-bottom: none;
}

.step-number {
    background: #10b981;
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
}

.step-icon {
    font-size: 24px;
}

.step-info {
    flex: 1;
}

.step-info strong {
    display: block;
    color: #1f2937;
    font-size: 14px;
}

.step-type {
    font-size: 11px;
    color: #6b7280;
    margin-top: 2px;
}

/* Actions */
.mega-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mega-footer {
    padding: 16px 20px;
    border-top: 2px solid #e5e7eb;
    background: white;
}

.btn-large {
    width: 100%;
    padding: 16px;
    font-size: 16px;
    font-weight: 700;
}

/* Mega Navigation */
.mega-navigation {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    padding: 20px;
    z-index: 2000;
    min-width: 380px;
    max-width: 90vw;
}

.nav-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.nav-progress {
    background: #10b981;
    color: white;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
}

.progress-bar {
    background: #e5e7eb;
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 16px;
}

.progress-fill {
    background: linear-gradient(90deg, #10b981, #059669);
    height: 100%;
    transition: width 0.3s ease;
}

.nav-current {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: #f0fdf4;
    border-radius: 12px;
    margin-bottom: 16px;
}

.nav-icon {
    font-size: 48px;
}

.nav-info {
    flex: 1;
}

.nav-label {
    font-size: 11px;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.nav-name {
    font-size: 18px;
    font-weight: 700;
    color: #1f2937;
    margin: 4px 0;
}

.nav-distance {
    font-size: 24px;
    font-weight: 700;
    color: #10b981;
}

.nav-actions {
    display: flex;
    gap: 8px;
}

.btn-nav {
    flex: 1;
    padding: 12px 16px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    font-size: 13px;
    background: #e5e7eb;
    color: #1f2937;
    transition: all 0.2s;
}

.btn-nav:hover {
    background: #d1d5db;
}

.btn-nav.btn-primary {
    background: #10b981;
    color: white;
}

.btn-nav.btn-primary:hover {
    background: #059669;
}

.btn-nav.btn-success {
    background: #10b981;
    color: white;
}

.btn-nav.btn-success:hover {
    background: #047857;
}

.btn-nav.btn-danger {
    background: #ef4444;
    color: white;
}

.btn-nav.btn-danger:hover {
    background: #dc2626;
}

/* Buttons */
.btn {
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 14px;
}

.btn-primary {
    background: #10b981;
    color: white;
}

.btn-primary:hover {
    background: #059669;
}

.btn-secondary {
    background: #6b7280;
    color: white;
}

.btn-secondary:hover {
    background: #4b5563;
}

.btn-success {
    background: #10b981;
    color: white;
}

.btn-success:hover {
    background: #047857;
}

.btn-small {
    padding: 6px 12px;
    font-size: 12px;
}

.btn-danger {
    background: #ef4444;
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
}

/* Info Box */
.info-box {
    background: #dbeafe;
    border-left: 4px solid #3b82f6;
    padding: 12px;
    border-radius: 6px;
    font-size: 13px;
    margin-bottom: 16px;
}

.loading, .no-data, .error {
    text-align: center;
    padding: 20px;
    color: #6b7280;
}

.error {
    color: #ef4444;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .mega-planner {
        right: 10px;
        width: calc(100vw - 20px);
        top: 60px;
        max-height: calc(100vh - 80px);
    }
    
    .mega-navigation {
        width: calc(100vw - 40px);
        min-width: 0;
        bottom: 10px;
        left: 20px;
        transform: none;
    }
    
    .transport-selector {
        grid-template-columns: 1fr;
    }
    
    .route-stats {
        grid-template-columns: 1fr;
    }
}

/* Scrollbar Styling */
.mega-content::-webkit-scrollbar,
.selection-list::-webkit-scrollbar,
.route-order::-webkit-scrollbar {
    width: 8px;
}

.mega-content::-webkit-scrollbar-track,
.selection-list::-webkit-scrollbar-track,
.route-order::-webkit-scrollbar-track {
    background: #f3f4f6;
    border-radius: 4px;
}

.mega-content::-webkit-scrollbar-thumb,
.selection-list::-webkit-scrollbar-thumb,
.route-order::-webkit-scrollbar-thumb {
    background: #10b981;
    border-radius: 4px;
}

.mega-content::-webkit-scrollbar-thumb:hover,
.selection-list::-webkit-scrollbar-thumb:hover,
.route-order::-webkit-scrollbar-thumb:hover {
    background: #059669;
}