/* assets/css/frontend.css */

/* Quote Button Styles - Only for non-Elementor buttons */
.pqr-quote-button:not(.elementor-button) {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    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(102, 126, 234, 0.3);
}

.pqr-quote-button:not(.elementor-button):hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
    color: white;
    text-decoration: none;
}

.pqr-quote-button:not(.elementor-button):active {
    transform: translateY(0);
}

.pqr-quote-button:not(.elementor-button).added {
    background: linear-gradient(135deg, #56ab2f 0%, #a8e6cf 100%);
}

/* Elementor Form Widget - Remove plugin styling conflicts */
.elementor-widget-pqr_quote_form .pqr-quote-form-widget {
    /* Remove default plugin styles for Elementor widget */
    background: unset;
    border: unset;
    border-radius: unset;
    box-shadow: unset;
    padding: unset;
    margin: unset;
}

.elementor-widget-pqr_quote_form .pqr-form-title {
    /* Let Elementor handle title styling */
    color: unset;
    font-size: unset;
    font-weight: unset;
    font-family: unset;
    margin: unset;
}

.elementor-widget-pqr_quote_form .pqr-form-description {
    /* Let Elementor handle description styling */
    color: unset;
    font-size: unset;
    font-family: unset;
    margin: unset;
}

.elementor-widget-pqr_quote_form .pqr-form-field label {
    /* Let Elementor handle label styling */
    color: unset;
    font-size: unset;
    font-weight: unset;
    font-family: unset;
    margin-bottom: unset;
}

.elementor-widget-pqr_quote_form .pqr-input,
.elementor-widget-pqr_quote_form .pqr-textarea {
    /* Let Elementor handle input styling */
    background: unset;
    border: unset;
    border-radius: unset;
    color: unset;
    font-size: unset;
    font-family: unset;
    padding: unset;
    width: 100%;
    display: block;
}

.elementor-widget-pqr_quote_form .pqr-input:focus,
.elementor-widget-pqr_quote_form .pqr-textarea:focus {
    /* Remove plugin focus styles for Elementor */
    outline: unset;
    border-color: unset;
    box-shadow: unset;
}

.elementor-widget-pqr_quote_form .pqr-submit-button {
    /* Let Elementor handle button styling */
    background: unset;
    color: unset;
    border: unset;
    border-radius: unset;
    font-size: unset;
    font-weight: unset;
    font-family: unset;
    padding: unset;
    box-shadow: unset;
    transform: none;
    transition: unset;
    cursor: pointer;
}

.elementor-widget-pqr_quote_form .pqr-submit-button:hover {
    /* Remove plugin hover effects for Elementor */
    background: unset;
    color: unset;
    border: unset;
    box-shadow: unset;
    transform: none;
}

.elementor-widget-pqr_quote_form .pqr-form-field {
    /* Let Elementor handle field spacing */
    margin-bottom: unset;
}

.elementor-widget-pqr_quote_form .pqr-form-footer {
    /* Let Elementor handle footer alignment */
    text-align: unset;
    margin-top: unset;
}

/* Keep essential functionality styles even in Elementor */
.elementor-widget-pqr_quote_form .pqr-required {
    color: #e74c3c;
    margin-left: 4px;
}

.elementor-widget-pqr_quote_form .pqr-quote-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    margin-bottom: 8px;
    background: #f9f9f9;
    border: 1px solid #ddd;
}

.elementor-widget-pqr_quote_form .pqr-remove-item {
    background: #e74c3c;
    color: white;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.elementor-widget-pqr_quote_form .pqr-items-count {
    background: #3498db;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8em;
    margin-left: 8px;
}

.elementor-widget-pqr_quote_form .pqr-submit-loading {
    /* Keep loading animation */
    animation: pulse 1.5s ease-in-out infinite;
}

/* Grid layout for form fields - works with Elementor styling */
.elementor-widget-pqr_quote_form .pqr-form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

/* Also apply clean styling to regular shortcode quote forms */
.pqr-quote-page .pqr-quote-form-section {
    background: transparent;
    padding: 20px 0;
    border: none;
    box-shadow: none;
    border-radius: 0;
}

.pqr-quote-page .pqr-quote-form-section h3 {
    color: inherit;
    font-family: inherit;
    font-size: inherit;
    font-weight: inherit;
}

.pqr-quote-page .pqr-quote-form-section p {
    color: inherit;
    font-family: inherit;
    font-size: inherit;
}

/* Quote Page Styles */
.pqr-quote-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.pqr-quote-header {
    text-align: center;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
}

.pqr-quote-header h2 {
    color: #2c3e50;
    font-size: 2.5em;
    margin-bottom: 10px;
    font-weight: 700;
}

.pqr-quote-header p {
    color: #7f8c8d;
    font-size: 1.1em;
    margin: 0;
}

/* Empty Quote State */
.pqr-empty-quote {
    text-align: center;
    padding: 60px 20px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 12px;
    margin: 40px 0;
}

.pqr-empty-icon {
    font-size: 4em;
    color: #bdc3c7;
    margin-bottom: 20px;
}

.pqr-empty-quote h3 {
    color: #2c3e50;
    font-size: 1.5em;
    margin-bottom: 10px;
}

.pqr-empty-quote p {
    color: #7f8c8d;
    font-size: 1.1em;
}

/* Quote Items List */
.pqr-items-list h3 {
    color: #2c3e50;
    font-size: 1.4em;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.pqr-items-count {
    background: #3498db;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: 600;
}

.pqr-items-grid {
    display: grid;
    gap: 15px;
    margin-bottom: 40px;
}

.pqr-quote-item {
    background: white;
    border: 2px solid #ecf0f1;
    border-radius: 8px;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.pqr-quote-item:hover {
    border-color: #3498db;
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(52, 152, 219, 0.2);
}

.pqr-item-content h4 {
    color: #2c3e50;
    margin: 0 0 8px 0;
    font-size: 1.1em;
    font-weight: 600;
}

.pqr-item-link {
    color: #3498db;
    text-decoration: none;
    font-size: 0.9em;
    font-weight: 500;
}

.pqr-item-link:hover {
    text-decoration: underline;
}

.pqr-remove-item {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.9em;
    transition: all 0.3s ease;
}

.pqr-remove-item:hover {
    background: #c0392b;
    transform: scale(1.05);
}

/* Quote Form */
.pqr-quote-form-section {
    background: transparent;
    padding: 20px 0;
}

.pqr-quote-form-section h3 {
    color: inherit;
    font-size: inherit;
    margin-bottom: 15px;
    font-weight: inherit;
    font-family: inherit;
}

.pqr-quote-form-section > p {
    color: inherit;
    margin-bottom: 20px;
    font-size: inherit;
    font-family: inherit;
}

.pqr-form-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.pqr-form-field {
    display: flex;
    flex-direction: column;
}

.pqr-form-field label {
    color: inherit;
    font-weight: inherit;
    margin-bottom: 8px;
    font-size: inherit;
    font-family: inherit;
}

.pqr-required {
    color: #e74c3c;
    margin-left: 4px;
}

.pqr-input, .pqr-textarea {
    padding: 12px;
    border: 1px solid #ddd;
    font-size: inherit;
    font-family: inherit;
    background: inherit;
    color: inherit;
}

.pqr-input:focus, .pqr-textarea:focus {
    outline: none;
    border-color: #0073aa;
}

.pqr-textarea {
    resize: vertical;
    min-height: 100px;
}

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

.pqr-submit-button {
    background: #0073aa;
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: inherit;
    font-weight: inherit;
    font-family: inherit;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.pqr-submit-button:hover {
    background: #005177;
}

.pqr-submit-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.pqr-submit-loading {
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.5; }
    100% { opacity: 1; }
}

/* Messages */
.pqr-messages {
    margin-top: 20px;
}

.pqr-message {
    padding: 15px 20px;
    border-radius: 6px;
    margin-bottom: 15px;
    font-weight: 500;
}

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

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

.pqr-message.info {
    background: #cce7ff;
    color: #004085;
    border: 1px solid #b3d9ff;
}

/* Responsive Design */
@media (max-width: 768px) {
    .pqr-quote-page {
        padding: 15px;
    }
    
    .pqr-quote-header h2 {
        font-size: 2em;
    }
    
    .pqr-quote-item {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .pqr-form-grid {
        grid-template-columns: 1fr;
    }
    
    .pqr-quote-form-section {
        padding: 20px;
    }
}