/* Основные стили */
.lg-container {
    width: 100%;
    max-width: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    padding: 30px;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #2c3e50;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* AI Ассистент */
.lg-ai-assistant {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.lg-ai-header {
    text-align: center;
    margin-bottom: 30px;
}

.lg-ai-title {
    font-size: 28px;
    font-weight: 700;
    margin: 0 0 10px 0;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.lg-ai-subtitle {
    font-size: 16px;
    color: #7f8c8d;
    margin: 0;
}

.lg-ai-questions {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.lg-question-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.lg-question-label {
    font-weight: 600;
    color: #2c3e50;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.lg-ai-input, .lg-ai-select {
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 15px;
    font-size: 16px;
    background: white;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.lg-ai-input:focus, .lg-ai-select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.lg-ai-generate-btn {
    grid-column: 1 / -1;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    border-radius: 12px;
    padding: 18px 30px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.lg-ai-generate-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

/* AI Предложения */
.lg-ai-suggestions {
    background: white;
    border-radius: 15px;
    padding: 25px;
    margin-top: 20px;
    border: 1px solid #e9ecef;
}

.lg-suggestions-title {
    text-align: center;
    margin-bottom: 20px;
    font-size: 22px;
    color: #2c3e50;
}

.lg-suggestions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.lg-suggestion-item {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.lg-suggestion-item:hover {
    transform: translateY(-3px);
    border-color: #667eea;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.lg-suggestion-preview {
    width: 80px;
    height: 80px;
    margin: 0 auto 15px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 14px;
}

.lg-suggestion-label {
    font-size: 14px;
    color: #2c3e50;
    margin-bottom: 5px;
}

.lg-suggestion-value {
    font-size: 12px;
    color: #7f8c8d;
}

/* Основной интерфейс */
.lg-main-interface {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.lg-control-panel {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.lg-control-section {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.lg-section-title {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 20px 0;
    color: #2c3e50;
    padding-bottom: 10px;
    border-bottom: 2px solid #f8f9fa;
}

/* Обновленные стили для элементов управления */
.lg-input-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

.lg-label {
    font-weight: 600;
    color: #2c3e50;
    font-size: 14px;
}

.lg-input {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 12px 15px;
    font-size: 16px;
    background: white;
    transition: all 0.3s ease;
    text-align: center;
}

.lg-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.lg-color-input {
    width: 100%;
    height: 50px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    cursor: pointer;
    background: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.lg-select {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 12px 15px;
    font-size: 16px;
    background: white;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.lg-range {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #e9ecef;
    outline: none;
    margin: 10px 0;
}

.lg-range-value {
    font-size: 14px;
    color: #667eea;
    text-align: center;
    font-weight: 600;
}

/* Кнопки стилей */
.lg-style-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 8px;
}

.lg-style-btn {
    padding: 12px 8px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 12px;
    font-weight: 500;
}

.lg-style-btn.active {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border-color: #667eea;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

/* Чекбоксы эффектов */
.lg-effect-checkboxes {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.lg-checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: background 0.3s ease;
}

.lg-checkbox-label:hover {
    background: #f8f9fa;
}

.lg-checkbox {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    border: 2px solid #ddd;
    cursor: pointer;
}

.lg-checkbox:checked {
    background: #667eea;
    border-color: #667eea;
}

.lg-checkbox-text {
    font-size: 14px;
    color: #2c3e50;
}

/* Область предпросмотра */
.lg-preview-container {
    text-align: center;
}

.lg-preview-wrapper {
    background: white;
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 25px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    border: 1px solid #e9ecef;
}

.lg-preview {
    background: 
        linear-gradient(45deg, #f8f9fa 25%, transparent 25%), 
        linear-gradient(-45deg, #f8f9fa 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, #f8f9fa 75%),
        linear-gradient(-45deg, transparent 75%, #f8f9fa 75%);
    background-size: 20px 20px;
    background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
    border-radius: 12px;
    padding: 40px;
    margin-bottom: 20px;
    display: inline-block;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lg-preview.dark-bg {
    background: #2c3e50;
}

.lg-preview.transparent-bg {
    background: none;
}

#lg-logo-canvas {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.lg-preview-controls {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.lg-preview-btn {
    padding: 10px 20px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.lg-preview-btn.active {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

/* Кнопки действий */
.lg-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.lg-btn {
    padding: 15px 25px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.lg-download-btn {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
}

.lg-download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

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

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

/* Блок поделиться */
.lg-share-section {
    text-align: center;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 25px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.lg-share-title {
    margin-bottom: 20px;
    color: #2c3e50;
    font-size: 20px;
}

.lg-share-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.lg-share-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.lg-share-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

/* Уведомления */
.lg-notification {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 100001;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 25px 35px;
    border-radius: 15px;
    font-size: 18px;
    font-weight: 600;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
    text-align: center;
}

/* Загрузка */
.lg-loading {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 100002;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 40px;
    text-align: center;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

.lg-loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: lg-spin 1s linear infinite;
    margin: 0 auto 20px;
}

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

.lg-loading-text {
    font-size: 16px;
    color: #2c3e50;
    font-weight: 600;
}

/* Адаптивность */
@media (max-width: 1024px) {
    .lg-control-panel {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 20px;
    }
    
    .lg-container {
        padding: 20px;
    }
    
    .lg-ai-questions {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .lg-control-panel {
        grid-template-columns: 1fr;
    }
    
    .lg-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .lg-btn {
        width: 100%;
        max-width: 300px;
        justify-content: center;
    }
    
    .lg-share-buttons {
        gap: 10px;
    }
    
    .lg-share-btn {
        width: 50px;
        height: 50px;
        font-size: 14px;
    }
    
    .lg-preview {
        padding: 20px;
        min-height: 200px;
    }
    
    .lg-ai-assistant,
    .lg-main-interface {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .lg-container {
        padding: 15px;
        border-radius: 15px;
    }
    
    .lg-preview {
        padding: 15px;
    }
    
    .lg-style-buttons {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .lg-notification {
        padding: 20px 25px;
        font-size: 16px;
        width: 90%;
        max-width: 300px;
    }
    
    .lg-ai-title {
        font-size: 24px;
    }
}

@media (max-width: 360px) {
    .lg-container {
        padding: 10px;
    }
    
    .lg-input, .lg-select, .lg-ai-input, .lg-ai-select {
        font-size: 14px;
        padding: 10px 12px;
    }
    
    .lg-share-btn {
        width: 45px;
        height: 45px;
        font-size: 12px;
    }
    
    .lg-btn {
        padding: 12px 20px;
        font-size: 14px;
    }
}