/* Main Container */
.rcg-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

/* Form Container */
.form-container {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 30px;
    margin-top: 20px;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 30px;
}

.header h1 {
    color: #2c3e50;
    margin: 0 0 10px 0;
    font-size: 28px;
}

.header h3 {
    color: #3498db;
    margin: 0 0 10px 0;
    font-size: 22px;
}

.header p {
    color: #7f8c8d;
    margin: 0;
}

/* Form Sections */
.form-section {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #ecf0f1;
}

.form-section h3 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 18px;
    padding-bottom: 10px;
    border-bottom: 1px solid #ecf0f1;
}

/* Form Rows and Columns */
.form-row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -15px;
}

.form-col {
    flex: 1;
    min-width: 200px;
    padding: 0 15px;
    margin-bottom: 20px;
}

/* Form Controls */
.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #2c3e50;
}

.form-label.required:after {
    content: ' *';
    color: #e74c3c;
}

.form-control {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.form-control:focus {
    border-color: #3498db;
    outline: none;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

/* Buttons */
.btn {
    display: inline-block;
    background: #3498db;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    transition: background-color 0.3s;
}

.btn:hover {
    background: #2980b9;
}

.btn-block {
    display: block;
    width: 100%;
}

/* Alerts */
.alert {
    padding: 15px;
    margin-bottom: 20px;
    border: 1px solid transparent;
    border-radius: 4px;
}

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

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

/* Pricing Summary */
.pricing-summary {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 4px;
    margin: 20px 0;
}

.pricing-summary h3 {
    margin-top: 0;
    color: #2c3e50;
    font-size: 18px;
    padding-bottom: 10px;
    border-bottom: 1px solid #dee2e6;
}

.price-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.price-total {
    font-weight: bold;
    font-size: 18px;
    padding-top: 10px;
    margin-top: 10px;
    border-top: 1px solid #dee2e6;
}

/* Responsive */
@media (max-width: 768px) {
    .form-col {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .form-container {
        padding: 20px 15px;
    }
}

/* Loading State */
.loading {
    position: relative;
    pointer-events: none;
    opacity: 0.7;
}

.loading:after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Form Validation */
input:invalid,
select:invalid {
    border-color: #e74c3c;
}

input:focus:invalid {
    box-shadow: 0 0 0 2px rgba(231, 76, 60, 0.2);
}

/* Checkbox and Radio Buttons */
.form-check {
    margin-bottom: 15px;
}

.form-check-input {
    margin-right: 8px;
}

/* Tooltips */
.tooltip {
    position: relative;
    display: inline-block;
    margin-left: 5px;
    color: #3498db;
    cursor: help;
}

.tooltip .tooltiptext {
    visibility: hidden;
    width: 200px;
    background-color: #333;
    color: #fff;
    text-align: center;
    border-radius: 6px;
    padding: 5px;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    transition: opacity 0.3s;
}

.tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
}

/* ========================================
   MODAL DE SELEÇÃO DE PRATOS (EVENTO)
   ======================================== */

/* Modal overlay */
.rcg-modal {
    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: 9999;
    padding: 20px;
    overflow-y: auto;
}

.rcg-modal.active {
    display: flex;
}

/* Modal content */
.rcg-modal-content {
    background: white;
    border-radius: 12px;
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 25px;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

/* Modal header */
.rcg-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e2e8f0;
}

.rcg-modal-close {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #64748b;
    line-height: 1;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s;
}

.rcg-modal-close:hover {
    background: #f1f5f9;
    color: #0f172a;
}

/* Modal sections */
.evento-modal-section {
    margin-bottom: 25px;
}

.evento-step-card {
    background: #f8fafc;
    border-radius: 8px;
    padding: 15px;
}

.evento-step-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
}

.evento-step-count {
    width: 32px;
    height: 32px;
    background: #4CAF50;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    flex-shrink: 0;
}

.evento-step-head h4 {
    margin: 0;
    color: #0f172a;
    font-size: 18px;
}

.evento-step-head p {
    margin: 5px 0 0 0;
    color: #64748b;
    font-size: 14px;
}

/* Opções list */
.evento-opcoes-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 12px;
}

.evento-opcao-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    gap: 12px;
}

.evento-opcao-card:hover {
    border-color: #4CAF50;
    box-shadow: 0 2px 8px rgba(76, 175, 80, 0.15);
}

.evento-opcao-card.active {
    border-color: #4CAF50;
    background: #f0fdf4;
}

.evento-opcao-thumb {
    width: 80px;
    height: 80px;
    border-radius: 6px;
    overflow: hidden;
    flex-shrink: 0;
    background: #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
}

.evento-opcao-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.evento-opcao-thumb.placeholder {
    color: #cbd5e1;
    font-size: 32px;
}

.evento-opcao-body {
    flex: 1;
    min-width: 0;
}

.evento-opcao-title {
    font-weight: 600;
    color: #0f172a;
    margin-bottom: 4px;
}

.evento-opcao-price {
    color: #4CAF50;
    font-weight: 600;
    margin-bottom: 6px;
}

.evento-opcao-desc {
    font-size: 13px;
    color: #64748b;
    margin: 0;
    line-height: 1.4;
}

.evento-opcao-harmonia {
    font-size: 12px;
    color: #8b5cf6;
    margin: 6px 0 0 0;
    display: flex;
    align-items: center;
    gap: 4px;
}

.evento-opcoes-empty {
    text-align: center;
    padding: 30px;
    color: #94a3b8;
    font-style: italic;
}

/* Modal footer */
.rcg-modal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 20px;
    margin-top: 20px;
    border-top: 2px solid #e2e8f0;
}

.rcg-modal-total {
    font-size: 20px;
    font-weight: 700;
    color: #4CAF50;
}

/* Mobile: Modal full-screen */
@media (max-width: 768px) {
    .rcg-modal {
        padding: 0;
        align-items: flex-start;
    }

    .rcg-modal-content {
        max-width: 100%;
        max-height: 100vh;
        height: 100vh;
        border-radius: 0;
        padding: 15px;
        display: flex;
        flex-direction: column;
    }

    .rcg-modal-header {
        flex-shrink: 0;
    }

    .rcg-modal-body {
        flex: 1;
        overflow-y: auto;
        margin: 0 -15px;
        padding: 0 15px;
    }

    .evento-modal-section {
        margin-bottom: 20px;
    }

    .evento-step-head {
        flex-direction: column;
        align-items: flex-start;
    }

    .evento-opcoes-list {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .evento-opcao-card {
        padding: 10px;
    }

    .evento-opcao-thumb {
        width: 60px;
        height: 60px;
    }

    .evento-opcao-title {
        font-size: 15px;
    }

    .evento-opcao-price {
        font-size: 14px;
    }

    .rcg-modal-footer {
        position: sticky;
        bottom: 0;
        background: white;
        padding: 15px;
        margin: 0 -15px -15px -15px;
        border-top: 2px solid #e2e8f0;
        flex-shrink: 0;
        flex-direction: column;
        gap: 10px;
    }

    .rcg-modal-footer .btn {
        width: 100%;
    }
}

/* Smartphones pequenos */
@media (max-width: 480px) {
    .evento-opcao-card {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .evento-opcao-thumb {
        width: 100%;
        height: 120px;
    }

    .rcg-modal-total {
        font-size: 18px;
    }
}