/* Sampieri Maridaje IA — estilos */

#smp-fab {
    position: fixed !important;
    bottom: 28px !important;
    left: 28px !important;
    z-index: 9998 !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    padding: 12px 20px !important;
    background: #132f59 !important;
    color: #fff !important;
    border: none !important;
    border-radius: 999px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    box-shadow: 0 4px 16px rgba(19,47,89,.35) !important;
    transition: transform .15s, box-shadow .15s !important;
    line-height: 1 !important;
    -webkit-appearance: none !important;
    font-family: inherit !important;
}
#smp-fab:hover  { transform: translateY(-2px) !important; box-shadow: 0 6px 20px rgba(19,47,89,.45) !important; }
#smp-fab:active { transform: scale(.97) !important; }

#smp-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.55);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    padding: 16px;
    backdrop-filter: blur(3px);
}
#smp-overlay.smp-open { display: flex; }

#smp-modal {
    background: #fff;
    width: 100%;
    max-width: 520px;
    max-height: 90vh;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,.3);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #222;
}

#smp-modal-header {
    padding: 18px 24px 14px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}
#smp-modal-header h2 {
    margin: 0 0 4px;
    font-size: 18px;
    font-weight: 700;
    color: #132f59;
}
#smp-modal-header p {
    margin: 0;
    font-size: 13px;
    color: #888;
}
#smp-close {
    background: none !important;
    border: none !important;
    font-size: 26px !important;
    line-height: 1 !important;
    color: #999 !important;
    cursor: pointer !important;
    padding: 0 !important;
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    min-height: 32px !important;
    max-width: 32px !important;
    max-height: 32px !important;
    border-radius: 50% !important;
    transition: background .15s, color .15s !important;
    flex-shrink: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: none !important;
    text-shadow: none !important;
    margin: 0 !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    font-family: inherit !important;
    font-weight: 400 !important;
}
#smp-close:hover,
#smp-close:focus,
#smp-close:active {
    background: #f0f0f0 !important;
    color: #333 !important;
    transform: none !important;
    box-shadow: none !important;
    outline: none !important;
}

#smp-modal-body {
    padding: 0 24px 16px;
    overflow-y: auto;
    flex: 1;
}

#smp-search-screen { padding-top: 16px; padding-bottom: 4px; }

.smp-platillos-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin: 0 0 14px;
}
.smp-platillo-btn {
    background: #f7f8fa;
    border: 1.5px solid transparent;
    border-radius: 10px;
    padding: 12px 6px;
    font-size: 12px;
    font-weight: 500;
    color: #333;
    cursor: pointer;
    transition: all .15s;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    font-family: inherit;
    line-height: 1.2;
    text-align: center;
    position: relative;
}
.smp-platillo-btn:hover    { background: #eef2f8; border-color: #dde3ec; }
.smp-platillo-btn.selected {
    background: #eef2f8;
    border-color: #132f59;
    color: #132f59;
    font-weight: 600;
}
.smp-platillo-btn.selected::after {
    content: "";
    position: absolute;
    top: 6px;
    right: 6px;
    width: 6px;
    height: 6px;
    background: #132f59;
    border-radius: 50%;
}
@keyframes smp-pulse-kf {
    0%   { transform: scale(1); }
    50%  { transform: scale(1.04); }
    100% { transform: scale(1); }
}
.smp-platillo-btn.smp-pulse { animation: smp-pulse-kf .25s ease; }
.smp-emoji { font-size: 22px; }

.smp-input-wrap {
    display: flex;
    align-items: stretch;
    gap: 8px;
    margin: 10px 0 10px;
}
#smp-custom-input {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    height: 44px !important;
    min-height: 44px !important;
    max-height: 44px !important;
    padding: 0 14px !important;
    margin: 0 !important;
    border: 1.5px solid #e0e4eb !important;
    border-radius: 10px !important;
    font-size: 14px !important;
    font-family: inherit !important;
    outline: none !important;
    transition: border-color .15s !important;
    box-sizing: border-box !important;
    line-height: 44px !important;
    background: #fff !important;
    color: #222 !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    box-shadow: none !important;
}
#smp-custom-input:focus { border-color: #132f59 !important; }

#smp-buscar-btn {
    height: 44px !important;
    min-height: 44px !important;
    max-height: 44px !important;
    background: #132f59 !important;
    color: #fff !important;
    border: 1.5px solid #132f59 !important;
    padding: 0 22px !important;
    margin: 0 !important;
    border-radius: 10px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    font-family: inherit !important;
    transition: background .15s !important;
    box-sizing: border-box !important;
    flex-shrink: 0 !important;
    line-height: 1 !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    text-shadow: none !important;
    box-shadow: none !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}
#smp-buscar-btn:hover { background: #0d2340 !important; border-color: #0d2340 !important; }

.smp-hint {
    margin: 0;
    font-size: 12px;
    color: #999;
    text-align: center;
    line-height: 1.4;
}

#smp-loading {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    gap: 16px;
    color: #666;
    font-size: 14px;
    text-align: center;
}
.smp-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid #e6e9ef;
    border-top-color: #132f59;
    border-radius: 50%;
    animation: smp-spin 0.9s linear infinite;
}
@keyframes smp-spin { to { transform: rotate(360deg); } }

#smp-results { display: none; }

.smp-intro {
    font-size: 14px;
    color: #444;
    line-height: 1.55;
    margin: 0 0 16px;
    padding: 14px 16px;
    background: #fafbfd;
    border-left: 3px solid #132f59;
    border-radius: 0 8px 8px 0;
    font-style: italic;
}

.smp-card {
    display: flex;
    gap: 12px;
    padding: 14px;
    border: 1px solid #ecedf0;
    border-radius: 12px;
    margin-bottom: 12px;
    transition: border-color .15s, box-shadow .15s;
}
.smp-card:hover { border-color: #d5d9e2; box-shadow: 0 4px 12px rgba(0,0,0,.04); }

.smp-card-img {
    width: 72px;
    height: 90px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
    background: #f5f5f5;
}

.smp-card-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.smp-card-nombre {
    margin: 0 0 5px;
    font-weight: 600;
    font-size: 14px;
    line-height: 1.3;
    color: #1a1a1a;
}
.smp-card-nombre a { color: inherit; text-decoration: none; }
.smp-card-nombre a:hover { color: #132f59; }

.smp-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 6px;
}
.smp-tag {
    font-size: 10px;
    padding: 2px 7px;
    background: #eef2f8;
    color: #132f59;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: .4px;
    font-weight: 600;
}

.smp-card-razon {
    margin: 0 0 10px;
    font-size: 12.5px;
    color: #555;
    line-height: 1.5;
    flex: 1;
}

.smp-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: auto;
}
.smp-precio {
    font-weight: 700;
    color: #132f59;
    font-size: 14px;
}
.smp-precio del { color: #aaa; font-weight: 400; margin-right: 4px; }

.smp-add-btn {
    background: #132f59;
    color: #fff !important;
    text-decoration: none !important;
    border: none;
    padding: 7px 14px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background .15s, transform .1s;
    display: inline-block;
}
.smp-add-btn:hover  { background: #0d2340; }
.smp-add-btn:active { transform: scale(.96); }

.smp-btn-nuevo {
    flex: 1;
    background: transparent;
    color: #132f59;
    border: 1px solid #d5d9e2;
    padding: 11px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    font-family: inherit;
    transition: background .15s;
}
.smp-btn-nuevo:hover { background: #f7f8fa; }

.smp-btn-mas {
    flex: 1;
    background: #132f59;
    color: #fff;
    border: 1px solid #132f59;
    padding: 11px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background .15s, transform .1s;
}
.smp-btn-mas:hover  { background: #0d2340; }
.smp-btn-mas:active { transform: scale(.98); }

.smp-actions {
    display: flex;
    gap: 8px;
    margin-top: 4px;
}

.smp-divider {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 20px 0 14px;
    color: #888;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .5px;
}
.smp-divider::before,
.smp-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: #e6e9ef;
}
.smp-divider span { white-space: nowrap; }

.smp-notice {
    margin: 10px 0;
    padding: 10px 12px;
    background: #fff8ec;
    border-left: 3px solid #e0a533;
    border-radius: 0 6px 6px 0;
    font-size: 12.5px;
    color: #7a5a10;
}

.smp-error {
    padding: 16px;
    background: #fff6f6;
    border-left: 3px solid #e74c3c;
    border-radius: 0 8px 8px 0;
    color: #c0392b;
    font-size: 13px;
    line-height: 1.5;
}

.smp-stock-agotado {
    font-size: 11px;
    color: #999;
    font-style: italic;
}

@media (max-width: 480px) {
    #smp-modal { max-width: 100%; max-height: 95vh; border-radius: 12px; }
    #smp-modal-header { padding: 16px 18px 12px; }
    #smp-modal-body { padding: 16px 18px 20px; }
    .smp-platillos-grid { grid-template-columns: repeat(3, 1fr); }
    .smp-platillo-btn { font-size: 11px; padding: 10px 4px; }
    .smp-emoji { font-size: 20px; }
    .smp-card-img { width: 60px; height: 75px; }
}
