/* QR Code Generator Styles */
.sth-qr-generator {
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    max-width: 1200px;
    margin: 0 auto;
}

/* Type Selector Tabs */
.sth-qr-type-selector {
    margin-bottom: 30px;
}

.sth-qr-type-selector h3 {
    margin: 0 0 20px 0;
    color: #333;
    font-size: 22px;
    text-align: center;
}

.sth-qr-type-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 25px;
}

.sth-qr-type-tab {
    padding: 12px 20px;
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 25px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: #495057;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sth-qr-type-tab:hover {
    background: #e9ecef;
    border-color: #dee2e6;
    transform: translateY(-2px);
}

.sth-qr-type-tab.active {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    border-color: #0056b3;
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
}

/* Content Sections */
.sth-qr-type-content {
    display: none;
    background: #f8f9fa;
    padding: 25px;
    border-radius: 10px;
    margin-bottom: 25px;
    border: 2px solid #e9ecef;
}

.sth-qr-type-content.active {
    display: block;
}

.sth-qr-type-content h4 {
    margin: 0 0 20px 0;
    color: #333;
    font-size: 20px;
    text-align: center;
    border-bottom: 2px solid #dee2e6;
    padding-bottom: 10px;
}

/* Input Groups */
.sth-qr-input-group {
    margin-bottom: 20px;
}

.sth-qr-input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #495057;
    font-size: 14px;
}

.sth-qr-input-field,
.sth-qr-textarea-field,
.sth-qr-select-field {
    width: 100%;
    padding: 15px;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
    background: white;
    box-sizing: border-box;
}

.sth-qr-input-field:focus,
.sth-qr-textarea-field:focus,
.sth-qr-select-field:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.sth-qr-textarea-field {
    resize: vertical;
    min-height: 100px;
}

.sth-qr-hint {
    font-size: 12px;
    color: #6c757d;
    margin-top: 5px;
    font-style: italic;
}

/* vCard Fields */
.sth-qr-vcard-fields {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

/* WiFi Fields */
.sth-qr-wifi-fields {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.sth-wifi-show-password {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    padding: 0;
    color: #6c757d;
}

.sth-qr-input-group {
    position: relative;
}

/* Email Fields */
.sth-qr-email-fields,
.sth-qr-sms-fields,
.sth-qr-location-fields {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

/* Location Button */
.sth-location-btn {
    padding: 12px 24px;
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sth-location-btn:hover {
    background: linear-gradient(135deg, #218838, #17a2b8);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

/* Customization Section */
.sth-qr-customization {
    background: #e9ecef;
    padding: 25px;
    border-radius: 10px;
    margin-bottom: 25px;
    border: 2px solid #dee2e6;
}

.sth-qr-customization h3 {
    margin: 0 0 20px 0;
    color: #333;
    font-size: 20px;
    text-align: center;
    border-bottom: 2px solid #adb5bd;
    padding-bottom: 10px;
}

.sth-qr-custom-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.sth-qr-custom-group {
    display: flex;
    flex-direction: column;
}

.sth-qr-custom-group label {
    font-weight: 600;
    color: #495057;
    margin-bottom: 8px;
    font-size: 14px;
}

.sth-qr-color-field {
    height: 50px;
    padding: 5px;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.sth-qr-color-field:focus {
    outline: none;
    border-color: #007bff;
}

/* Generate Button */
.sth-qr-generate-btn {
    width: 100%;
    padding: 18px 30px;
    background: linear-gradient(135deg, #6f42c1, #563d7c);
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 30px;
}

.sth-qr-generate-btn:hover {
    background: linear-gradient(135deg, #563d7c, #495057);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(111, 66, 193, 0.4);
}

.sth-qr-generate-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Result Section */
.sth-qr-result {
    margin-top: 30px;
    padding: 30px;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: 15px;
    border-left: 6px solid #6f42c1;
}

.sth-qr-result-header h3 {
    margin: 0 0 25px 0;
    color: #333;
    text-align: center;
    font-size: 24px;
}

.sth-qr-preview {
    text-align: center;
    margin-bottom: 25px;
    padding: 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

#sth-qr-canvas {
    max-width: 100%;
    height: auto;
    border: 1px solid #dee2e6;
    border-radius: 8px;
}

/* Info Section */
.sth-qr-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 25px;
}

.sth-qr-info-item {
    background: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    text-align: center;
    border-top: 3px solid #6f42c1;
}

.sth-qr-info-label {
    display: block;
    font-size: 12px;
    color: #6c757d;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-bottom: 5px;
}

.sth-qr-info-value {
    font-size: 16px;
    font-weight: bold;
    color: #333;
}

/* Download Section */
.sth-qr-download-section {
    background: white;
    padding: 25px;
    border-radius: 10px;
    margin-bottom: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.sth-qr-download-section h4 {
    margin: 0 0 20px 0;
    color: #333;
    text-align: center;
    font-size: 18px;
}

.sth-qr-download-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.sth-qr-download-btn {
    padding: 15px 30px;
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    border: none;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-width: 150px;
}

.sth-qr-download-btn:hover {
    background: linear-gradient(135deg, #218838, #17a2b8);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

/* Tips Section */
.sth-qr-tips {
    background: linear-gradient(135deg, #fff3cd, #ffeaa7);
    padding: 25px;
    border-radius: 10px;
    border-left: 4px solid #ffc107;
}

.sth-qr-tips h4 {
    margin: 0 0 15px 0;
    color: #856404;
    font-size: 18px;
}

.sth-qr-tips ul {
    margin: 0;
    padding-left: 20px;
}

.sth-qr-tips li {
    margin-bottom: 8px;
    color: #856404;
    line-height: 1.5;
}

/* Error Messages */
.sth-qr-error {
    background: #f8d7da;
    color: #721c24;
    padding: 15px;
    border-radius: 8px;
    margin: 15px 0;
    border: 1px solid #f5c6cb;
    font-weight: 600;
    text-align: center;
}

/* Success Messages */
.sth-qr-success {
    background: #d4edda;
    color: #155724;
    padding: 15px;
    border-radius: 8px;
    margin: 15px 0;
    border: 1px solid #c3e6cb;
    font-weight: 600;
    text-align: center;
}

/* Loading State */
.sth-qr-loading {
    text-align: center;
    padding: 40px;
    color: #6c757d;
}

.sth-qr-loading::after {
    content: "";
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .sth-qr-generator {
        padding: 20px;
        margin: 10px;
    }
    
    .sth-qr-type-tabs {
        justify-content: flex-start;
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 10px;
    }
    
    .sth-qr-type-tab {
        flex-shrink: 0;
        padding: 10px 16px;
        font-size: 12px;
    }
    
    .sth-qr-vcard-fields,
    .sth-qr-wifi-fields,
    .sth-qr-email-fields,
    .sth-qr-sms-fields,
    .sth-qr-location-fields {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .sth-qr-custom-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .sth-qr-info {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .sth-qr-download-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .sth-qr-download-btn {
        width: 100%;
        max-width: 250px;
    }
}

@media (max-width: 480px) {
    .sth-qr-custom-grid {
        grid-template-columns: 1fr;
    }
    
    .sth-qr-info {
        grid-template-columns: 1fr;
    }
    
    .sth-qr-type-content {
        padding: 15px;
    }
    
    .sth-qr-result {
        padding: 20px;
    }
    
    .sth-qr-customization {
        padding: 15px;
    }
}