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

body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #333;
    overflow-x: hidden;
}

#app {
    width: 100vw;
    height: 100vh;
    position: relative;
}

/* Loading Screen */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.logo-animation {
    font-size: 48px;
    font-weight: bold;
    color: white;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.7);
    padding: 20px;
    background: rgba(0,0,0,0.3);
    border-radius: 10px;
    animation: logoFadeIn 2s ease-in-out;
}

@keyframes logoFadeIn {
    0% {
        opacity: 0;
        transform: translateX(-100px) rotateY(-45deg) scale(1.5);
    }
    100% {
        opacity: 1;
        transform: translateX(0) rotateY(0) scale(1);
    }
}

.loading-text {
    color: white;
    font-size: 18px;
    font-weight: bold;
    background: rgba(0,0,0,0.3);
    padding: 10px 20px;
    border-radius: 5px;
    margin-top: 20px;
}

/* Main Container */
.view-container {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    background: rgba(255,255,255,0.95);
    border-radius: 10px;
    padding: 20px;
    min-height: calc(100vh - 40px);
    margin-top: 20px;
    margin-bottom: 20px;
}

/* Form Elements */
.form-group {
    display: flex;
    align-items: center;
    margin: 10px 0;
    gap: 10px;
}

.form-label {
    font-weight: bold;
    color: #000;
    min-width: 100px;
}

.form-input {
    padding: 10px;
    border: 2px solid #ccc;
    border-radius: 5px;
    font-size: 16px;
    font-weight: bold;
    flex: 1;
}

.form-input:focus {
    outline: none;
    border-color: #2196F3;
}

/* Radio Buttons */
.radio-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 20px 0;
}

.radio-option {
    display: flex;
    align-items: center;
    padding: 15px;
    background: rgba(255,255,255,0.9);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.radio-option:hover {
    background: rgba(255,255,255,1);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    border-color: #2196F3;
}

.radio-option input[type="radio"] {
    margin-right: 15px;
    transform: scale(1.5);
}

.radio-option label {
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    flex: 1;
}

/* Buttons */
.btn {
    padding: 15px 25px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 150px;
    height: 65px;
}

.btn-primary {
    background: #2196F3;
    color: white;
}

.btn-primary:hover {
    background: #1976D2;
    transform: translateY(-2px);
}

.btn-primary:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

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

.btn-secondary:hover {
    background: #555;
    transform: translateY(-2px);
}

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

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

.btn-success {
    background: #4CAF50;
    color: white;
}

.btn-success:hover {
    background: #45a049;
}

.btn-group {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin: 20px 0;
    flex-wrap: wrap;
}

/* Data Grid */
.data-grid {
    background: rgba(255,255,255,0.95);
    border-radius: 8px;
    overflow: hidden;
    margin: 20px 0;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.data-grid table {
    width: 100%;
    border-collapse: collapse;
}

.data-grid th,
.data-grid td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
    font-weight: bold;
}

.data-grid th {
    background: #f5f5f5;
    color: #333;
}

.data-grid tr:hover {
    background: #f0f8ff;
}

.data-grid tr.selected {
    background: #e3f2fd;
}

/* Question Headers */
.question-header {
    color: #F3150A;
    font-size: 32px;
    font-weight: bold;
    text-align: center;
    margin: 20px 0;
}

.question-text {
    font-size: 18px;
    font-weight: bold;
    text-align: center;
    margin: 15px 0;
    background: rgba(255,255,255,0.9);
    padding: 15px;
    border-radius: 8px;
}

/* Modal/Popup */
.modal-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal {
    background: white;
    border-radius: 10px;
    padding: 20px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 8px 16px rgba(0,0,0,0.3);
}

.modal-header {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 15px;
    color: #333;
}

.modal-content {
    margin: 15px 0;
    line-height: 1.5;
}

.modal-footer {
    text-align: center;
    margin-top: 20px;
}

/* GPS/Height Inputs */
.height-input-group {
    display: flex;
    gap: 20px;
    justify-content: space-around;
    margin: 20px 0;
}

.height-input-container {
    flex: 1;
    text-align: center;
    background: rgba(255,255,255,0.9);
    padding: 20px;
    border-radius: 10px;
    border: 2px solid #e0e0e0;
}

.height-input-container .form-input {
    margin: 10px 0;
    text-align: center;
    font-size: 18px;
}

.gps-button {
    background: #4CAF50;
    color: white;
    margin-top: 10px;
    width: 100%;
}

.gps-button:hover {
    background: #45a049;
}

/* Results Display */
.result-container {
    background: rgba(255,255,255,0.95);
    padding: 20px;
    border-radius: 10px;
    margin: 20px 0;
    border: 2px solid #e0e0e0;
}

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

.result-value {
    font-size: 24px;
    font-weight: bold;
    color: #E93737;
    text-align: center;
    margin: 10px 0;
    padding: 15px;
    background: #fff;
    border-radius: 8px;
    border: 2px solid #E93737;
}

.result-warning {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
    padding: 15px;
    border-radius: 8px;
    margin: 15px 0;
    font-weight: bold;
}

.result-strategy {
    background: #f8f9fa;
    border-left: 4px solid #E93737;
    padding: 15px;
    margin: 15px 0;
    color: #E93737;
    font-weight: bold;
}

/* Loading Indicator */
.loading-indicator {
    display: none;
    text-align: center;
    margin: 20px 0;
}

.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

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

/* Language Selection */
.language-selection {
    margin: 30px 0;
}

.language-selection h3 {
    color: #333;
    margin-bottom: 20px;
    font-size: 18px;
}

.language-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.language-option {
    padding: 15px 30px;
    background: #f0f0f0;
    color: #333;
    border: 3px solid #2196F3;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    font-size: 16px;
    transition: all 0.3s ease;
    min-width: 120px;
    text-align: center;
}

.language-option:hover {
    background: #e0e0e0;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.language-option.selected {
    background: #2196F3;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.4);
}

/* Start View Styling */
.start-view {
    background: transparent;
    text-align: center;
    padding: 40px 20px;
}

.app-logo {
    font-size: 36px;
    font-weight: bold;
    color: #2196F3;
    margin-bottom: 10px;
}

.app-subtitle {
    font-size: 18px;
    color: #666;
    background: rgba(255,255,255,0.9);
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 20px;
}

/* Intro Content */
.intro-content {
    text-align: left;
}

.intro-text h2 {
    color: #2196F3;
    margin-bottom: 20px;
    text-align: center;
}

.intro-text h3 {
    color: #f44336;
    margin: 20px 0 10px 0;
}

.intro-text p {
    line-height: 1.6;
    margin-bottom: 15px;
}

.copyright {
    background: #f5f5f5;
    padding: 15px;
    border-radius: 5px;
    margin-top: 20px;
    font-size: 14px;
}

/* User Form */
.user-form {
    background: rgba(255,255,255,0.9);
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    border: 2px solid #e0e0e0;
}

.user-form h3 {
    margin: 15px 0 10px 0;
    color: #333;
}

/* Special Elements */
.important-notice {
    background: #e3f2fd;
    border: 2px solid #2196F3;
    padding: 15px;
    border-radius: 8px;
    margin: 20px 0;
    text-align: center;
}

.oedem-image {
    text-align: center;
    margin: 20px 0;
}

.oedem-image img {
    max-width: 300px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* Responsive Design */
@media (max-width: 768px) {
    .view-container {
        margin: 10px;
        padding: 15px;
    }
    
    .height-input-group {
        flex-direction: column;
    }
    
    .btn-group {
        flex-direction: column;
        align-items: center;
    }
    
    .form-group {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .form-label {
        min-width: auto;
        margin-bottom: 5px;
    }
    
    .language-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .language-option {
        width: 200px;
    }
    
    .result-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
}


/* Chart Container */
.chart-container {
    background: rgba(255,255,255,0.95);
    border-radius: 10px;
    padding: 20px;
    margin: 20px 0;
    height: 400px;
    position: relative;
}

.chart-info {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin: 20px 0;
}

.chart-info ul {
    list-style: none;
    padding: 0;
    margin: 10px 0;
}

.chart-info li {
    padding: 5px 0;
    font-weight: bold;
}

/* Detail View Styling */
.detail-container {
    background: rgba(255,255,255,0.95);
    border-radius: 10px;
    padding: 20px;
    margin: 20px 0;
}

.detail-section {
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 2px solid #e0e0e0;
}

.detail-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.detail-section h3 {
    color: #2196F3;
    margin-bottom: 15px;
    font-size: 18px;
    border-left: 4px solid #2196F3;
    padding-left: 10px;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-row span:first-child {
    font-weight: bold;
    color: #555;
    flex: 1;
}

.detail-row span:last-child {
    flex: 1;
    text-align: right;
    color: #333;
}

.detail-row .highlight {
    font-size: 18px;
    font-weight: bold;
    color: #E93737;
}

/* Result boxes */
.result-box {
    padding: 15px;
    border-radius: 8px;
    margin: 10px 0;
}

.result-box.warning {
    background: #fff3cd;
    border: 2px solid #ffeaa7;
    color: #856404;
}

.result-box.ok {
    background: #d4edda;
    border: 2px solid #c3e6cb;
    color: #155724;
}

.result-status {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 10px;
}

.result-threshold {
    font-size: 14px;
}

.strategy-box {
    background: #f8f9fa;
    border-left: 4px solid #E93737;
    padding: 15px;
    margin: 10px 0;
    color: #E93737;
    font-weight: bold;
    line-height: 1.5;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .detail-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .detail-row span:last-child {
        text-align: left;
    }
    
    .chart-container {
        height: 300px;
        padding: 10px;
    }
}

/* Utility Classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.font-bold { font-weight: bold; }
.hidden { display: none !important; }
.visible { display: block; }
.flex { display: flex; }
.flex-column { flex-direction: column; }
.align-center { align-items: center; }
.justify-center { justify-content: center; }
.gap-10 { gap: 10px; }
.gap-20 { gap: 20px; }
.mt-10 { margin-top: 10px; }
.mt-20 { margin-top: 20px; }
.mb-10 { margin-bottom: 10px; }
.mb-20 { margin-bottom: 20px; }
.p-10 { padding: 10px; }
.p-20 { padding: 20px; }