/* ===== RESET BÁSICO SLICK CAROUSEL ===== */
.erc-carousel-container {
    width: 100%;
    margin: 0px 20px;
    position: relative;
}

.erc-carousel {
    display: block;
    margin: 0 auto;
    max-width: 1200px;
}

.erc-carousel .slick-list {
    margin: 0 -15px;
    padding: 20px 0;
}

.erc-carousel .slick-slide {
    padding: 0 15px;
    transition: transform 0.3s ease;
}

.erc-carousel .slick-slide.slick-active {
    transform: scale(1);
}

/* ===== ESTILOS DE LAS CARDS ===== */
.erc-card {
    background: #fff;
    border-radius: 16px;
    padding: 25px;
    margin: 25px 25px;
    transition: all 0.3s ease-in-out;
    border: 1px solid #000000;
    height: auto;
    min-height: 320px;
    display: flex !important;
    flex-direction: column;
    overflow: hidden;
    box-sizing: border-box;
    opacity: 0.9;
}

.erc-card:hover {
    transform: translateY(-5px);
    box-shadow: 0px 8px 0px black;
    opacity: 1;
}

/* CONTENIDO CENTRADO */
.erc-card-inner {
    display: flex;
    flex-direction: column;
    height: 100%;
    justify-content: center;
    align-items: center;
    text-align: center;
    margin: auto;
    max-width: 100%;
    box-sizing: border-box;
}

.erc-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 15px;
    border: 3px solid #f8f9fa;
}

.erc-card h3 {
    margin: 0 0 12px;
    font-size: 1.2rem;
    color: #27ba08;
    line-height: 1.3;
    font-weight: 600;
    width: 100%;
}

.erc-card p {
    flex-grow: 1;
    margin: 0 0 15px;
    color: #4b5563;
    line-height: 1.5;
    font-size: 0.95rem;
    text-align: center;
    width: 100%;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    display: block;
}

.erc-stars {
    font-size: 1.35rem;
    margin: 8px 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2px;
    width: 100%;
}

.erc-rating-text {
    display: none;
}

.erc-meta {
    font-size: 0.92rem;
    color: #374151;
    font-weight: 500;
    margin: 5px 0;
    width: 100%;
}

.erc-date {
    font-size: 0.8rem;
    color: #9ca3af;
    margin-top: 8px;
    width: 100%;
}

/* ===== BOTÓN DE AÑADIR RESEÑA ===== */
.erc-actions {
    text-align: center;
    margin: 30px 0;
}

.erc-open-popup {
    background-color: #61CE7000;
    font-family: var(--e-global-typography-secondary-font-family), Sans-serif;
    font-weight: var(--e-global-typography-secondary-font-weight);
    fill: #1E1E1E;
    color: #1E1E1E;
    transition-duration: 800ms;
    border-style: solid;
    border-width: 2px 2px 2px 2px;
    border-radius: 10px 10px 10px 10px;
}

.erc-open-popup:hover {
    background-color: #1e1e1e;
    transform: translateY(-2px);
    box-shadow: 0 6px 10px rgba(37, 99, 235, 0.3);
}

/* ===== POPUP ===== */
.erc-popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    z-index: 9999;
    backdrop-filter: blur(3px);
    overflow: auto;
    padding: 20px;
    box-sizing: border-box;
}

.erc-popup-content {
    position: relative;
    background: #fff;
    border-radius: 16px;
    padding: 30px;
    width: 450px;
    max-width: 100%;
    margin: 50px auto;
    box-shadow: 0 20px 40px rgba(0,0,0,0.25);
    animation: fadeInScale 0.3s ease;
}

.erc-close-popup {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 28px;
    cursor: pointer;
    color: #9ca3af;
    background: none;
    border: none;
    transition: color 0.2s;
    line-height: 1;
}

.erc-close-popup:hover {
    color: #374151;
}

/* ===== FORMULARIO ===== */
.erc-form-group {
    margin-bottom: 20px;
}

.erc-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #374151;
}

.erc-form-group input,
.erc-form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

.erc-form-group input:focus,
.erc-form-group textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.erc-form-error {
    display: block;
    color: #ef4444;
    font-size: 0.85rem;
    margin-top: 5px;
    min-height: 20px;
}

/* ===== STARS INTERACTIVAS ===== */
.erc-rating {
    font-size: 1.8rem;
    color: #e5e7eb;
    cursor: pointer;
    letter-spacing: 4px;
    text-align: center;
}

.erc-rating .star {
    transition: all 0.2s;
    display: inline-block;
}

.erc-rating .star:hover {
    transform: scale(1.2);
}

.erc-rating .star.filled {
    color: #f59e0b;
}

/* ===== BOTONES ===== */
.erc-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 20px;
}

.erc-form-actions button {
    padding: 12px 20px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.erc-submit-btn {
    background: #10b981;
    color: white;
}

.erc-submit-btn:hover {
    background: #059669;
}

.erc-form-actions .erc-close-popup {
    position: static;
    background: #6b7280;
    color: white;
    font-size: 1rem;
    padding: 12px 20px;
}

.erc-form-actions .erc-close-popup:hover {
    background: #4b5563;
    color: white;
}

.erc-form-message {
    margin-top: 15px;
    padding: 10px;
    border-radius: 8px;
    text-align: center;
    display: none;
}

.erc-form-message.success {
    background: #dcfce7;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.erc-form-message.error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* ===== SLICK DOTS ===== */
.slick-dots {
    text-align: center;
    margin: 20px 0 0;
    padding: 0;
    list-style: none;
}

.slick-dots li {
    display: inline-block;
    margin: 0 5px;
}

.slick-dots li button {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #d1d5db;
    border: none;
    text-indent: -9999px;
    overflow: hidden;
    transition: background 0.3s;
    cursor: pointer;
}

.slick-dots li.slick-active button {
    background: #27ba08;
    transform: scale(1.2);
}

/* Ocultar flechas */
.slick-prev, .slick-next {
    display: none !important;
}

/* ===== ANIMACIONES ===== */
@keyframes fadeInScale {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes shake {
    0%,100%{transform:translateX(0);}
    10%,30%,50%,70%,90%{transform:translateX(-5px);}
    20%,40%,60%,80%{transform:translateX(5px);}
}

.erc-shake {
    animation: shake 0.5s;
    border-color: #ef4444 !important;
}

/* Loading animation */
.erc-loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    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); }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .erc-carousel .slick-slide { padding: 0 10px; }
    .erc-card { padding: 20px; min-height: 300px; }
}

@media (max-width: 768px) {
    .erc-carousel .slick-list { margin: 0 -10px; }
    .erc-carousel .slick-slide { padding: 0 10px; }
    .erc-card { min-width: auto; min-height: 280px; }
    .erc-popup-content { margin: 20px auto; padding: 25px 20px; }
    .erc-form-actions { flex-direction: column; }
    .erc-form-actions button { width: 100%; }
}

@media (max-width: 480px) {
    .erc-card { padding: 15px; min-height: 250px; }
    .erc-stars { font-size: 1.2rem; }
    .erc-popup-content { margin: 10px auto; padding: 20px 15px; }
}

[type=button]:focus,[type=button]:hover,[type=submit]:focus,[type=submit]:hover,button:focus,button:hover {
    background-color: #1e1e1e;
}
