/**
 * =====================================================
 * JuShape - Stylesheet
 * =====================================================
 * 
 * Main stylesheet for JuShape Web Application
 * Extracted from index.html for better organization
 * 
 * @author JuShape Development Team
 * @version 2.1 - Production Launch Ready
 */

/* J+G Brand Colors */
:root {
    --jg-primary: #2E8B8B;      /* J+G Petrol/Türkis */
    --jg-primary-dark: #1E7A7A; /* Darker variant */
    --jg-primary-light: #3A9F9F; /* Lighter variant */
    --jg-secondary: #666666;     /* J+G Text gray */
    --jg-accent: #20A0A0;        /* Vibrant accent */
}

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

body {
    font-family: Arial, sans-serif;
    background-color: #f5f5f5;
    padding: 20px;
}


.container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    overflow: hidden;
}

.header {
    background: var(--jg-primary);
    color: white;
    padding: 20px;
    text-align: center;
}

.header h1 {
    font-size: 2em;
    margin-bottom: 5px;
}

.header p {
    opacity: 0.8;
}

.menu-bar {
    background: var(--jg-primary-dark);
    padding: 10px 20px;
    display: flex;
    gap: 20px;
}

.menu-item {
    color: white;
    text-decoration: none;
    padding: 8px 15px;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
}

.menu-item:hover {
    background: rgba(255,255,255,0.2);
}

.main-content {
    display: flex;
    min-height: 600px;
    position: relative;
}

.left-panel {
    flex: 1;
    padding: 20px;
    border-right: 1px solid #eee;
}

.middle-panel {
    flex: 1;
    padding: 20px;
    border-right: 1px solid #eee;
}

.right-panel {
    flex: 2;
    padding: 20px;
    border-right: none;
    position: relative;
}

.preview-3d-container {
    width: 100%;
    height: 500px;
    border: 2px solid var(--jg-primary);
    border-radius: 8px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.preview-3d-header {
    background: var(--jg-primary);
    color: white;
    padding: 10px 15px;
    font-weight: bold;
    border-radius: 6px 6px 0 0;
    margin: -2px -2px 0 -2px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.preview-controls {
    display: flex;
    gap: 10px;
}

.preview-btn {
    background: rgba(255,255,255,0.2);
    border: 1px solid rgba(255,255,255,0.3);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s;
}

.preview-btn:hover {
    background: rgba(255,255,255,0.3);
    transform: translateY(-1px);
}

.preview-btn.active {
    background: var(--jg-primary-dark);
    border-color: var(--jg-primary-dark);
}

#canvas3d {
    width: 100%;
    height: calc(100% - 50px);
    display: block;
}

.preview-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #666;
    font-size: 14px;
}


.section {
    margin-bottom: 30px;
}

.section-title {
    font-size: 1.2em;
    color: var(--jg-primary-dark);
    margin-bottom: 15px;
    border-bottom: 2px solid var(--jg-primary);
    padding-bottom: 5px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #555;
}

.form-group input, .form-group select {
    width: 100%;
    padding: 8px 12px;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-group input:focus, .form-group select:focus {
    outline: none;
    border-color: var(--jg-primary);
}

.form-container {
    border: 2px solid #ecf0f1;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
    background: #f9f9f9;
}

.form-container h3 {
    color: var(--jg-primary-dark);
    margin-bottom: 15px;
    text-align: center;
}

.button-group {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
    padding: 20px;
    background: #ecf0f1;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: all 0.3s;
}

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

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

.btn-success {
    background: var(--jg-accent);
    color: white;
}

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

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

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

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.4);
}

/* System Settings Sections */

.advanced-section {
    margin-bottom: 25px;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #f9f9f9;
}

.advanced-section h4 {
    color: var(--jg-primary-dark);
    margin-bottom: 15px;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
}


.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 20px;
    border-radius: 10px;
    width: 80%;
    max-width: 600px;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-header {
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover {
    color: black;
}

.alert {
    padding: 15px;
    margin: 10px 0;
    border-radius: 5px;
    font-weight: bold;
}

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

.alert-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.progress-container {
    margin: 20px 0;
    display: none;
}

.progress-bar {
    width: 100%;
    height: 20px;
    background-color: #ecf0f1;
    border-radius: 10px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background-color: var(--jg-primary);
    transition: width 0.3s;
    width: 0%;
}

.hidden {
    display: none !important;
}

@media (max-width: 1200px) {
    .main-content {
        flex-direction: column;
    }
    
    .left-panel, .middle-panel, .right-panel {
        border-right: none;
        border-bottom: 1px solid #eee;
        flex: none;
    }
    
    .preview-3d-container {
        height: 400px;
    }
}

@media (max-width: 768px) {
    .left-panel {
        flex: none;
    }
    
    .preview-controls {
        flex-direction: column;
        gap: 5px;
    }
    
    .preview-btn {
        font-size: 10px;
        padding: 3px 6px;
    }
}