:root {
    --bg-main: #f8f9fa;
    --bg-white: #ffffff;
    --border-color: #dadce0;
    --text-primary: #202124;
    --text-secondary: #5f6368;
    --text-muted: #70757a;
    
    --gcp-blue: #1a73e8;
    --gcp-blue-hover: #1557b0;
    --gcp-blue-light: #e8f0fe;
    
    --success: #137333;
    --success-light: #e6f4ea;
    --danger: #c5221f;
    --danger-light: #fce8e6;
    --warning: #b06000;
    --warning-light: #fef7e0;
    --info: #1a73e8;
    --info-light: #e8f0fe;
    
    --header-height: 56px;
    --nav-height: 60px;
    --font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body, html {
    margin: 0;
    padding: 0;
    font-family: var(--font-family);
    background-color: var(--bg-main);
    color: var(--text-primary);
    height: 100vh;
    width: 100vw;
    overflow: hidden;
}

[v-cloak] {
    display: none !important;
}

/* APP CONTAINERS */
.pweb-app {
    display: flex;
    flex-direction: column;
    /* Die Höhe wurde von 100vh auf 90vh verringert, damit die Navigationsleiste und die Buttons am unteren Bildschirmrand auf Smartphones nicht abgeschnitten werden. */
    height: 90vh;
    width: 100vw;
    position: relative;
}

/* HEADER BAR */
.pweb-header {
    height: var(--header-height);
    background-color: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.pweb-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
    font-weight: 500;
    color: var(--text-primary);
}

.pweb-brand i {
    color: var(--gcp-blue);
    font-size: 18px;
}

.pweb-brand span {
    font-weight: 600;
}

.pweb-header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* BOTTOM NAVIGATION */
.pweb-bottom-nav {
    height: var(--nav-height);
    background-color: var(--bg-white);
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-around;
    align-items: center;
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding-bottom: env(safe-area-inset-bottom, 0px);
}

.pweb-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 10px;
    font-weight: 500;
    height: 100%;
    flex: 1;
    cursor: pointer;
    transition: color 0.2s, background-color 0.2s;
    position: relative;
}

.pweb-nav-item i {
    font-size: 18px;
    margin-bottom: 4px;
    transition: transform 0.2s;
}

.pweb-nav-item.active {
    color: var(--gcp-blue);
}

.pweb-nav-item.active::after {
    content: '';
    position: absolute;
    top: 0;
    left: 20%;
    right: 20%;
    height: 3px;
    background-color: var(--gcp-blue);
    border-radius: 0 0 3px 3px;
}

.pweb-nav-item:active i {
    transform: scale(0.9);
}

/* CONTENT CONTAINER */
.pweb-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    margin-bottom: var(--nav-height);
    background-color: var(--bg-main);
    display: flex;
    flex-direction: column;
    gap: 16px;
    -webkit-overflow-scrolling: touch;
}

.pweb-content.no-padding {
    padding: 0;
}

/* CARD SYSTEM */
.pweb-card {
    background-color: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    position: relative;
    box-shadow: 0 1px 2px 0 rgba(60,64,67,0.15);
}

.pweb-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    border-bottom: 1px solid #f1f3f4;
    padding-bottom: 8px;
}

.pweb-card-title {
    font-size: 14px;
    font-weight: 600;
    margin: 0;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.pweb-card-title i {
    color: var(--gcp-blue);
}

.pweb-card-value {
    font-size: 28px;
    font-weight: 500;
    color: var(--text-primary);
    margin: 8px 0;
}

.pweb-card-footer {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* LIST ITEMS */
.pweb-list-item {
    background-color: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    cursor: pointer;
    transition: background-color 0.2s, border-color 0.2s;
}

.pweb-list-item:active {
    background-color: var(--gcp-blue-light);
    border-color: var(--gcp-blue);
}

/* BADGES */
.badge-gcp {
    display: inline-flex;
    align-items: center;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    line-height: 1;
}

.badge-gcp.success {
    background-color: var(--success-light);
    color: var(--success);
}

.badge-gcp.danger {
    background-color: var(--danger-light);
    color: var(--danger);
}

.badge-gcp.warning {
    background-color: var(--warning-light);
    color: var(--warning);
}

.badge-gcp.info {
    background-color: var(--info-light);
    color: var(--info);
}

/* FORMS & BUTTONS */
.gcp-form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 14px;
}

.gcp-form-group label {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
}

.gcp-input, .gcp-select, .gcp-textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    background-color: var(--bg-white);
    color: var(--text-primary);
    font-family: var(--font-family);
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.gcp-input:focus, .gcp-select:focus, .gcp-textarea:focus {
    border-color: var(--gcp-blue);
}

.gcp-textarea {
    resize: none;
    min-height: 80px;
}

.btn-gcp-primary {
    background-color: var(--gcp-blue);
    color: white;
    border: 1px solid transparent;
    padding: 10px 16px;
    border-radius: 4px;
    font-weight: 500;
    font-size: 13px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background-color 0.2s;
}

.btn-gcp-primary:hover {
    background-color: var(--gcp-blue-hover);
}

.btn-gcp-secondary {
    background-color: var(--bg-white);
    color: var(--gcp-blue);
    border: 1px solid var(--border-color);
    padding: 10px 16px;
    border-radius: 4px;
    font-weight: 500;
    font-size: 13px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background-color 0.2s, border-color 0.2s;
}

.btn-gcp-secondary:hover {
    background-color: #f1f3f4;
    border-color: #dadce0;
}

.btn-gcp-danger {
    background-color: var(--danger-light);
    color: var(--danger);
    border: 1px solid transparent;
    padding: 10px 16px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* MAP OVERLAYS */
#pweb-map {
    width: 100%;
    height: 100%;
    z-index: 1;
}

.pweb-map-overlay {
    position: absolute;
    top: calc(var(--header-height) + 12px);
    left: 12px;
    right: 12px;
    z-index: 10;
    background-color: rgba(255, 255, 255, 0.95);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    backdrop-filter: blur(4px);
}

.pweb-map-info-box {
    position: absolute;
    bottom: calc(var(--nav-height) + 12px);
    left: 12px;
    right: 12px;
    z-index: 10;
    background-color: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.pweb-map-info-item {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    margin-bottom: 6px;
}

.pweb-map-info-label {
    color: var(--text-secondary);
    font-weight: 500;
}

.pweb-map-info-value {
    color: var(--text-primary);
    font-weight: 600;
}

/* LOGIN SCREEN */
.pweb-login-screen {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--bg-main);
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.pweb-login-card {
    background-color: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 32px 24px;
    width: 100%;
    max-width: 380px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* DIAGNOSE HUD */
.pweb-hud-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.pweb-hud-widget {
    background-color: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    cursor: pointer;
}

.pweb-hud-widget-label {
    font-size: 11px;
    color: var(--text-secondary);
    font-weight: 600;
    text-transform: uppercase;
}

.pweb-hud-widget-value {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    margin-top: 4px;
}

/* CHAT BOX */
.pweb-chat-container {
    display: flex;
    flex-direction: column;
    height: 100%;
    gap: 12px;
}

.pweb-chat-messages {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 8px;
    background-color: #f8f9fa;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    max-height: 280px;
}

.pweb-chat-bubble {
    padding: 10px 12px;
    border-radius: 8px;
    max-width: 85%;
    font-size: 13px;
    line-height: 1.4;
}

.pweb-chat-bubble.admin {
    background-color: var(--bg-white);
    border: 1px solid var(--border-color);
    align-self: flex-start;
}

.pweb-chat-bubble.driver {
    background-color: var(--gcp-blue-light);
    color: var(--gcp-blue);
    align-self: flex-end;
}

/* SOS / EMERGENCY PANELS */
.pweb-sos-button {
    background: linear-gradient(135deg, #d93025, #c5221f);
    color: white;
    border: none;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    font-weight: 700;
    font-size: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 10px rgba(217, 48, 37, 0.3);
}

.pweb-sos-button:active {
    transform: scale(0.98);
}

/* MODALS */
.pweb-modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.4);
    z-index: 150;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    backdrop-filter: blur(2px);
}

.pweb-modal {
    background-color: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    width: 100%;
    max-width: 450px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    max-height: 90vh;
}

.pweb-modal-header {
    padding: 16px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.pweb-modal-header h3 {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
}

.pweb-modal-close {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: var(--text-secondary);
}

.pweb-modal-body {
    padding: 16px;
    overflow-y: auto;
}

.pweb-modal-footer {
    padding: 12px 16px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

.unfall-tabs {
    display: flex;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 12px;
}

.unfall-tab {
    flex: 1;
    padding: 10px;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    color: var(--text-secondary);
}

.unfall-tab.active {
    color: var(--gcp-blue);
    border-bottom: 2px solid var(--gcp-blue);
}

.photo-grid-preview {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-top: 8px;
}

.photo-preview-item {
    position: relative;
    aspect-ratio: 1;
    border-radius: 4px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.photo-preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-delete-btn {
    position: absolute;
    top: 2px;
    right: 2px;
    background: rgba(0,0,0,0.6);
    color: white;
    border: none;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    font-size: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

/* UTILS */
.text-center { text-align: center; }
.w-100 { width: 100%; }
.mt-1 { margin-top: 4px; }
.mt-2 { margin-top: 8px; }
.mb-2 { margin-bottom: 8px; }
.flex-row { display: flex; align-items: center; gap: 8px; }
.space-between { display: flex; justify-content: space-between; align-items: center; }

/* GERMAN LICENSE PLATE VEHICLE MARKER */
.vehicle-plate-div-icon {
    background: transparent !important;
    border: none !important;
}
.vehicle-plate-marker-wrapper {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    user-select: none;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), filter 0.2s ease;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.45));
}
.vehicle-plate-marker-wrapper:hover {
    transform: scale(1.12) translateY(-3px);
    filter: drop-shadow(0 6px 16px rgba(26, 115, 232, 0.6));
    z-index: 9999 !important;
}
.vehicle-plate-badge {
    display: flex;
    align-items: center;
    background: #ffffff;
    color: #111827;
    border: 1.5px solid #111827;
    border-radius: 4px;
    padding: 2px 7px 2px 3px;
    height: 25px;
    box-sizing: border-box;
    font-family: 'FE-Schrift', 'DIN Alternate', 'Montserrat', 'Consolas', -apple-system, monospace, sans-serif;
    font-weight: 800;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.9), inset 0 -1px 0 rgba(0,0,0,0.15), 0 2px 5px rgba(0,0,0,0.3);
    white-space: nowrap;
    position: relative;
}
.vehicle-plate-badge.is-electric {
    border-color: #059669;
}
.plate-eu-strip {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #003399;
    color: #ffffff;
    width: 13px;
    height: 100%;
    margin-right: 6px;
    margin-left: -2px;
    border-top-left-radius: 2px;
    border-bottom-left-radius: 2px;
    padding: 1px 0;
    line-height: 1;
}
.plate-eu-flag {
    font-size: 7px;
    line-height: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}
.plate-eu-country {
    font-size: 7.5px;
    font-weight: 900;
    letter-spacing: -0.2px;
    color: #ffffff;
    font-family: Arial, sans-serif;
    margin-top: 1px;
}
.plate-number-text {
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.8px;
    color: #0f172a;
    text-transform: uppercase;
    line-height: 1;
}
.plate-electric-badge {
    font-size: 11px;
    font-weight: 900;
    color: #059669;
    margin-left: 3px;
    background: rgba(5, 150, 105, 0.12);
    padding: 1px 3px;
    border-radius: 2px;
}
.plate-pointer-stem {
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 6px solid #111827;
    margin-top: -1px;
}
.plate-pin-dot {
    width: 8px;
    height: 8px;
    background: #1a73e8;
    border: 2px solid #ffffff;
    border-radius: 50%;
    box-shadow: 0 0 6px rgba(26, 115, 232, 0.8);
    margin-top: -1px;
}
.vehicle-plate-marker-wrapper.is-live .plate-pin-dot {
    background: #1a73e8;
    box-shadow: 0 0 10px #1a73e8;
    animation: live-pin-pulse 1.5s infinite;
}
@keyframes live-pin-pulse {
    0% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(26, 115, 232, 0.7); }
    70% { transform: scale(1.2); box-shadow: 0 0 0 8px rgba(26, 115, 232, 0); }
    100% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(26, 115, 232, 0); }
}

.trip-start-div-icon {
    background: transparent !important;
    border: none !important;
}
