:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #e74c3c;
    --light-color: #ecf0f1;
    --dark-color: #34495e;
    --success-color: #2ecc71;
    --warning-color: #f39c12;
    --danger-color: #e74c3c;
    --text-color: #333;
    --border-radius: 8px;
    --box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #f5f7fa;
    padding: 0;
    margin: 0;
}

.container {
    max-width: 100%;
    padding: 1rem;
    margin: 0 auto;
}

h1, h2, h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

h1 {
    text-align: center;
    margin: 1rem 0 1.5rem;
    font-size: 1.8rem;
}

h2 {
    font-size: 1.4rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 0.5rem;
    margin-bottom: 1rem;
}

.card {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: var(--transition);
}

.form-control:focus {
    border-color: var(--secondary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
}

.button-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background-color: var(--secondary-color);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
    transition: var(--transition);
}

.btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.btn:active {
    transform: translateY(1px);
}

.btn-primary {
    background-color: var(--secondary-color);
}

.btn-secondary {
    background-color: var(--dark-color);
}

.btn-danger {
    background-color: var(--danger-color);
}

.btn-small {
    padding: 0.4rem 0.8rem;
    font-size: 0.9rem;
}

.btn[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
}

#status-container {
    background-color: #f8f9fa;
}

#tracking-status {
    font-weight: bold;
    margin-bottom: 0.5rem;
}

#position-info {
    font-size: 0.9rem;
    color: #666;
}

#map-container {
    padding: 0;
    overflow: hidden;
}

#map {
    height: 300px;
    width: 100%;
    border-radius: var(--border-radius);
}

.footer {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
    font-size: 0.9rem;
    color: #777;
}

.admin-link {
    display: inline-block;
    margin-top: 0.5rem;
    color: var(--secondary-color);
    text-decoration: none;
}

.admin-link:hover {
    text-decoration: underline;
}

/* Status-Anzeigen */
.status-active {
    color: var(--success-color);
}

.status-inactive {
    color: var(--danger-color);
}

.status-waiting {
    color: var(--warning-color);
}

/* Marker-Styles */
.user-marker .marker-dot {
    width: 12px;
    height: 12px;
    background-color: var(--accent-color);
    border-radius: 50%;
    border: 2px solid white;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
}

.marker-online .marker-dot {
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.3);
        opacity: 0.7;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Responsive Anpassungen */
@media (min-width: 768px) {
    .container {
        max-width: 720px;
    }
    
    h1 {
        font-size: 2.2rem;
    }
    
    #map {
        height: 400px;
    }
    
    .button-group {
        justify-content: center;
    }
}

@media (min-width: 992px) {
    .container {
        max-width: 960px;
    }
}

/* Offline/Online Benachrichtigungen */
.offline-notification,
.online-notification,
.sync-status {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    padding: 10px 15px;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    animation: slide-in 0.5s ease-out;
    max-width: 90%;
}

.offline-notification {
    background-color: #fff3cd;
    border: 1px solid #ffeeba;
    color: #856404;
}

.online-notification {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.sync-status {
    background-color: #cce5ff;
    border: 1px solid #b8daff;
    color: #004085;
    padding: 15px;
}

.offline-message,
.online-message,
.sync-message {
    display: flex;
    align-items: center;
}

.offline-icon,
.online-icon,
.sync-icon {
    margin-right: 10px;
    font-size: 1.2em;
}

.sync-progress {
    margin-top: 8px;
    height: 5px;
    background-color: #e9ecef;
    border-radius: 3px;
    overflow: hidden;
    width: 100%;
}

.sync-progress-bar {
    height: 100%;
    background-color: #007bff;
    transition: width 0.3s ease;
}

@keyframes slide-in {
    from {
        transform: translate(-50%, -20px);
        opacity: 0;
    }
    to {
        transform: translate(-50%, 0);
        opacity: 1;
    }
}

.fade-out {
    opacity: 0;
    transition: opacity 1s ease;
}
