/**
 * Vélemények shortcode stílusok
 */

.velemenyek-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: "mundial", Sans-serif;
    color: #050327;
}

.velemenyek-container * {
    font-family: "mundial", Sans-serif;
}

.velemenyek-title {
    text-align: center;
    margin-bottom: 15px;
    font-size: 35px;
    color: #050327;
    letter-spacing: 1px;
}

.velemenyek-description {
    text-align: center;
    margin-bottom: 30px;
    color: #050327;
    line-height: 1.7;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.velemenyek-description p {
    margin-bottom: 15px;
}

.velemenyek-description img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

/* Statisztikák */
.velemenyek-stats {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
}

.stats-summary {
    display: flex;
    gap: 40px;
    align-items: center;
    flex-wrap: wrap;
}

.average-rating {
    text-align: center;
    min-width: 150px;
}

.average-number {
    font-size: 48px;
    font-weight: bold;
    color: #050327;
    display: block;
}

.average-stars {
    margin: 10px 0;
}

.total-reviews {
    color: #050327;
    font-size: 14px;
}

.rating-breakdown {
    flex: 1;
    min-width: 250px;
}

.rating-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.rating-label {
    min-width: 40px;
    font-size: 14px;
    color: #050327;
}

.rating-bar {
    flex: 1;
    height: 12px;
    background: #e0e0e0;
    border-radius: 6px;
    overflow: hidden;
}

.rating-fill {
    height: 100%;
    background: #dce9d7;
    border-radius: 6px;
    transition: width 0.3s ease;
}

.rating-count {
    min-width: 30px;
    text-align: right;
    font-size: 14px;
    color: #050327;
}

/* Csillagok */
.stars {
    display: inline-flex;
    gap: 2px;
}

.star {
    color: #ddd;
    font-size: 18px;
}

.star.filled {
    color: #ffc107;
}

.star.half {
    color: #ffc107; /* fallback, ha a background-clip nem támogatott */
    background: linear-gradient(90deg, #ffc107 50%, #ddd 50%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Vélemények lista */
.velemenyek-list {
    display: grid;
    gap: 20px;
        margin-bottom: 30px;
}

.velemenyek-container.columns-2 .velemenyek-list {
    grid-template-columns: repeat(2, 1fr);
}

.velemenyek-container.columns-3 .velemenyek-list {
    grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 768px) {
    .velemenyek-container.columns-2 .velemenyek-list,
    .velemenyek-container.columns-3 .velemenyek-list {
        grid-template-columns: 1fr;
    }
    .stats-summary {
        flex-direction: column;
    }
}

.velemeny-item {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px;
}

.velemeny-header {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.velemeny-avatar img {
    border-radius: 50%;
    width: 60px;
    height: 60px;
    object-fit: cover;
}

.velemeny-meta {
    flex: 1;
}

.velemeny-author {
    font-weight: 600;
    color: #050327;
    display: block;
    margin-bottom: 5px;
}

.verified-badge {
    background: #dce9d7;
    color: #050327;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 5px;
}

.velemeny-rating {
    margin: 5px 0;
}

.velemeny-date {
    font-size: 12px;
    color: #050327;
    opacity: 0.7;
}

.velemeny-product {
    background: #f8f9fa;
    padding: 10px;
    border-radius: 8px;
    margin-bottom: 15px;
}

.velemeny-product a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #050327;
    text-decoration: none;
    font-size: 14px;
}

.velemeny-product a:hover {
    opacity: 0.8;
}

.velemeny-product img {
    border-radius: 4px;
    width: 40px;
    height: 40px;
    object-fit: cover;
}

.velemeny-content {
    color: #050327;
    line-height: 1.6;
}

.velemeny-content p {
    margin: 0;
}

.no-reviews {
    text-align: center;
    padding: 40px;
    color: #050327;
    background: #f8f9fa;
    border-radius: 12px;
    line-height: 1.7;
}

.no-reviews p {
    margin: 0 0 10px 0;
}

.no-reviews p:last-child {
    margin-bottom: 0;
}

.no-reviews .no-reviews-title {
    font-size: 18px;
    margin-bottom: 12px;
}

/* Lapozás */
.velemenyek-pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
}

.velemenyek-pagination .page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: #f0f0f0;
    color: #050327;
    text-decoration: none;
    font-weight: 500;
}

.velemenyek-pagination .page-link:hover {
    background: #dce9d7;
}

.velemenyek-pagination .page-link.active {
    background: #dce9d7;
    color: #050327;
}

/* Vélemény űrlap */
.velemenyek-form-container {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
}

.velemenyek-form-title {
    margin-bottom: 20px;
    font-size: 35px;
    color: #050327;
    letter-spacing: 1px;
}

.velemenyek-form .form-row {
    margin-bottom: 20px;
}

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

@media (max-width: 600px) {
    .velemenyek-form .form-row-grid {
        grid-template-columns: 1fr;
    }
}

.velemenyek-form .form-row-grid .form-row {
    margin-bottom: 0;
}

.velemenyek-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #050327;
}

.velemenyek-form input[type="text"],
.velemenyek-form input[type="email"],
.velemenyek-form textarea,
.velemenyek-form select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 15px;
    font-family: "mundial", Sans-serif;
    color: #050327;
}

.velemenyek-form input:focus,
.velemenyek-form textarea:focus,
.velemenyek-form select:focus {
    border-color: #dce9d7;
    outline: none;
}

.velemenyek-form textarea {
    min-height: 120px;
    resize: vertical;
}

.velemenyek-form .field-description {
    font-size: 12px;
    color: #050327;
    margin-top: 5px;
    font-style: italic;
    opacity: 0.7;
}

/* Csillagos értékelés választó */
.velemenyek-form .form-row-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
    width: 100%;
    padding: 0;
    margin-left: 0;
    margin-right: 0;
}

/* WooCommerce .form-row clearfix pseudo elemek elrejtése flex layoutban */
.velemenyek-form .form-row-actions::before,
.velemenyek-form .form-row-actions::after,
.velemenyek-form .form-row-rating::before,
.velemenyek-form .form-row-rating::after {
    content: none !important;
    display: none !important;
}

.velemenyek-form .form-row-actions .form-row-rating {
    margin: 0;
    padding: 0;
    flex: 0 0 auto;
}

.velemenyek-form .form-row-actions .form-row-rating .rating-label-text {
    padding-left: 0;
    margin-left: 0;
}

.velemenyek-form .form-row-actions button[type="submit"] {
    margin: 0 0 0 auto;
}

.velemenyek-form .form-row-rating {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.velemenyek-form .form-row-rating .rating-label-text {
    margin-bottom: 0;
    line-height: 1;
}

.velemenyek-form .form-row-rating .field-error {
    flex-basis: 100%;
}

.star-rating-select {
    display: flex;
    gap: 5px;
    flex-direction: row-reverse;
    justify-content: flex-end;
}

.star-rating-select input {
    display: none;
}

.star-rating-select label {
    font-size: 30px;
    color: #ddd;
    cursor: pointer;
    transition: color 0.2s ease;
    margin-bottom: 0;
}

.star-rating-select label:hover,
.star-rating-select label:hover ~ label,
.star-rating-select input:checked ~ label {
    color: #ffc107;
}

.velemenyek-form button[type="submit"] {
    background: #dce9d7 !important;
    color: #050327 !important;
    border: none;
    padding: 14px 30px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    font-family: "mundial", Sans-serif;
}

.velemenyek-form button[type="submit"]:hover {
    opacity: 0.9;
}

.form-message {
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    transition: opacity 0.5s ease, transform 0.5s ease, max-height 0.5s ease, padding 0.5s ease, margin 0.5s ease;
    opacity: 1;
    max-height: 200px;
    overflow: hidden;
}

.form-message.fade-out {
    opacity: 0;
    transform: translateY(-10px);
    max-height: 0;
    padding-top: 0;
    padding-bottom: 0;
    margin-bottom: 0;
}

.form-message.success {
    background: #dce9d7;
    color: #050327;
    border: 1px solid #c3d9be;
}

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

.login-notice {
    text-align: center;
    padding: 20px;
    background: #fff3cd;
    border-radius: 8px;
    color: #856404;
}

.login-notice a {
    color: #050327;
}

/* Validációs hibaüzenetek */
.velemenyek-form .field-error {
    display: block;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    margin-top: 0;
    font-size: 13px;
    color: #c0392b;
    font-weight: 500;
    transition: max-height 0.25s ease, opacity 0.25s ease, margin-top 0.25s ease;
}

.velemenyek-form .field-error.show {
    max-height: 60px;
    opacity: 1;
    margin-top: 6px;
}

.velemenyek-form .field-error.show::before {
    content: "⚠ ";
    margin-right: 4px;
}

.velemenyek-form input.has-error,
.velemenyek-form textarea.has-error,
.velemenyek-form select.has-error {
    border-color: #c0392b !important;
    background-color: #fff5f4;
    box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.08);
}

.velemenyek-form .star-rating-select.has-error {
    padding: 6px 10px;
    border: 1px solid #c0392b;
    border-radius: 8px;
    background-color: #fff5f4;
}

/* Kiválasztott termék megjelenítése */
.velemeny-product-info {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.velemeny-product-info label {
    color: #050327;
    margin-bottom: 10px;
}

.selected-product {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #fff;
    padding: 10px;
    border-radius: 6px;
}

.selected-product img {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: 6px;
}

.selected-product .product-name {
    font-weight: 600;
    color: #050327;
    font-size: 15px;
}

/* Honeypot (embereknek láthatatlan, botoknak csapda) */
.velemenyek-hp {
    position: absolute !important;
    left: -9999px !important;
    top: -9999px !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

/* =========================================================
   prefers-reduced-motion — mozgásérzékeny felhasználók
   ========================================================= */
@media (prefers-reduced-motion: reduce) {
    .rating-fill,
    .star-rating-select label,
    .form-message,
    .velemenyek-form .field-error {
        transition: none !important;
    }
    .form-message.fade-out {
        transform: none !important;
    }
}

/* =========================================================
   ÁLTALÁNOS VÉLEMÉNYEK ([altalanos_velemeny]) — kép szerinti
   megjelenés. Minden szelektor .altalanos-velemenyek alá
   scope-olva, így a [velemenyek] (termék-vélemények) érintetlen.
   Betűtípus: lokális Plus Jakarta Sans (css/fonts.css).
   ========================================================= */

.velemenyek-container.altalanos-velemenyek,
.velemenyek-container.altalanos-velemenyek * {
    font-family: 'Plus Jakarta Sans', sans-serif !important;
}



.altalanos-velemenyek .velemenyek-title {
    text-align: center;
    color: #333333;
    font-size: 30px;
    font-weight: 700;
    letter-spacing: 0;
    margin-bottom: 20px;
}

/* --- Kapszula-fejléc: átlag + csillagok + darabszám --- */
.altalanos-velemenyek .velemenyek-stats {
    background: #ffffff;
    border-radius: 70px;
    padding: 18px 28px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
    display: flex;
    justify-content: center;
    margin: 0 auto 30px;
    max-width: max-content;
}

.altalanos-velemenyek .average-rating {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
    min-width: 0;
    text-align: center;
}

.altalanos-velemenyek .average-number {
    font-size: 40px;
    font-weight: 900;
    color: #333333;
    display: inline;
    line-height: 1;
}

.altalanos-velemenyek .average-stars {
    margin: 0;
}

.altalanos-velemenyek .average-stars .star {
    font-size: 18px;
}

.altalanos-velemenyek .total-reviews {
    color: #8A8470;
    font-size: 15px;
    font-weight: 700;
}

/* --- Csillagok aranyba --- */
.altalanos-velemenyek .star {
    color: #e0d6c2;
    font-size: 18px;
}

.altalanos-velemenyek .star.filled {
    color: #c09a5e;
}

.altalanos-velemenyek .star.half {
    color: #c09a5e;
    background: linear-gradient(90deg, #c09a5e 50%, #e0d6c2 50%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* --- Űrlap --- */
.altalanos-velemenyek .velemenyek-form-container {
    background: #ffffff;
    border: none;
    border-radius: 12px;
    padding: 28px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
    margin-bottom: 40px;
}

.altalanos-velemenyek .velemenyek-form-title {
    color: #333333;
    font-size: 25px;
    font-weight: 800;
    letter-spacing: 0;
    margin-bottom: 6px;
}

.altalanos-velemenyek .velemenyek-form-subtitle {
    color: #6B6657;
    font-size: 16px;
    line-height: 1.7;
    margin: 0 0 22px;
    width: 850px;
}

.altalanos-velemenyek .velemenyek-form label {
    color: #333333;
    font-weight: 700;
    font-size: 14px;
    margin-bottom: 8px;
}

.altalanos-velemenyek .rating-label-text {
    color: #333333;
    font-weight: 600;
    font-size: 14px;
}

.altalanos-velemenyek .rating-hint {
    color: #999999;
    font-size: 12px;
}

.altalanos-velemenyek .velemenyek-form input[type="text"],
.altalanos-velemenyek .velemenyek-form input[type="email"],
.altalanos-velemenyek .velemenyek-form textarea {
    border: 1px solid #E3DDCD;
    border-radius: 14px;
    color: #333333;
    background: #FAF8F2;
}

.altalanos-velemenyek .velemenyek-form input:focus,
.altalanos-velemenyek .velemenyek-form textarea:focus {
    border-color: #c09a5e;
    outline: none;
    box-shadow: 0 0 0 3px rgba(192, 154, 94, 0.12);
}

.altalanos-velemenyek .velemenyek-form .form-row-rating {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
}

.altalanos-velemenyek .rating-stars-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.altalanos-velemenyek .star-rating-select label {
    color: #e0d6c2;
    margin-bottom: 0;
    font-size: 28px;
}

.altalanos-velemenyek .star-rating-select label:hover,
.altalanos-velemenyek .star-rating-select label:hover ~ label,
.altalanos-velemenyek .star-rating-select input:checked ~ label {
    color: #c09a5e;
}

.altalanos-velemenyek .velemenyek-form .velemeny-consent {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-weight: 400;
    font-size: 13px;
    color: #555555;
    margin-bottom: 0;
    line-height: 1.5;
    cursor: pointer;
}

.altalanos-velemenyek .velemeny-consent input[type="checkbox"] {
    margin-top: 3px;
    accent-color: #c09a5e;
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
}

.altalanos-velemenyek .velemenyek-form .form-row-actions {
    justify-content: flex-end;
}

.altalanos-velemenyek .velemenyek-form .form-row-actions button[type="submit"] {
    background: #c09a5e !important;
    color: #ffffff !important;
    border: none;
    padding: 14px 30px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    margin: 0;
    transition: background 0.2s ease;
}

.altalanos-velemenyek .velemenyek-form .form-row-actions button[type="submit"]:hover {
    background: #a4814a !important;
}

/* --- Listafejléc + rendezés --- */
.altalanos-velemenyek .velemenyek-list-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}

.altalanos-velemenyek .velemenyek-list-title {
    font-size: 20px;
    font-weight: 700;
    color: #333333;
    margin: 0;
}

.altalanos-velemenyek .velemeny-sort {
    display: inline-flex;
    gap: 8px;
}

.altalanos-velemenyek .velemeny-sort-btn {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 999px;
    border: 1px solid #e0d6c2;
    background: #ffffff;
    color: #666666;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.altalanos-velemenyek .velemeny-sort-btn:hover {
    border-color: #c09a5e;
    color: #333333;
}

.altalanos-velemenyek .velemeny-sort-btn.active {
    background: #c09a5e;
    border-color: #c09a5e;
    color: #ffffff;
}

/* --- Vélemény rács --- */
.altalanos-velemenyek .velemenyek-list {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.altalanos-velemenyek .velemeny-item {
    background: #ffffff;
    border: none;
    border-radius: 12px;
    padding: 22px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
}

.altalanos-velemenyek .velemeny-top {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.altalanos-velemenyek .velemeny-avatar-initials {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #c09a5e;
    color: #ffffff;
    font-weight: 700;
    font-size: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    letter-spacing: 0.5px;
}

.altalanos-velemenyek .velemeny-id {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-width: 0;
}

.altalanos-velemenyek .velemeny-author {
    font-weight: 700;
    color: #333333;
    font-size: 15px;
    margin-bottom: 2px;
}

.altalanos-velemenyek .verified-text {
    color: #1e7a4d;
    font-size: 12px;
    font-weight: 600;
}

.altalanos-velemenyek .velemeny-date {
    display: block;
    color: #999999;
    font-size: 12px;
    margin: 12px 0 0;
    padding-top: 10px;
    border-top: 1px solid #f0ece4;
}

.altalanos-velemenyek .velemeny-rating {
    margin: 0 0 8px;
}

.altalanos-velemenyek .velemeny-top .velemeny-rating {
    margin: 0 0 0 auto;
}

.altalanos-velemenyek .velemeny-rating .star {
    font-size: 16px;
}

.altalanos-velemenyek .velemeny-content {
    color: #444444;
    line-height: 1.6;
    font-size: 14px;
}

/* --- Üres állapot --- */
.altalanos-velemenyek .no-reviews {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    color: #333333;
    grid-column: 1 / -1;
}

/* --- További vélemények betöltése --- */
.altalanos-velemenyek .velemeny-load-more {
    display: block;
    margin: 0 auto;
    padding: 14px 32px;
    background: #ffffff;
    color: #333333;
    border: 1px solid #e0d6c2;
    border-radius: 999px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.altalanos-velemenyek .velemeny-load-more:hover {
    background: #f3f3f3;
    border-color: #c09a5e;
}

.altalanos-velemenyek .velemeny-load-more:disabled {
    opacity: 0.6;
    cursor: default;
}

.altalanos-velemenyek .velemeny-load-more[hidden] {
    display: none;
}

/* --- Üzenetek --- */
.altalanos-velemenyek .form-message.success {
    background: #e8f5ee;
    color: #1e7a4d;
    border: 1px solid #c3e6d2;
}

.altalanos-velemenyek .field-error {
    color: #c0392b;
}

/* --- Reszponzív --- */
@media (max-width: 768px) {
    .altalanos-velemenyek .velemenyek-list {
        grid-template-columns: 1fr;
    }
    .altalanos-velemenyek .velemenyek-list-head {
        justify-content: center;
        text-align: center;
    }
    .altalanos-velemenyek .velemeny-date {
        margin-left: 0;
    }
}

@media (max-width: 600px) {
    .altalanos-velemenyek .velemeny-top {
        flex-wrap: wrap;
    }
}

@media (prefers-reduced-motion: reduce) {
    .altalanos-velemenyek .velemeny-sort-btn,
    .altalanos-velemenyek .velemeny-load-more,
    .altalanos-velemenyek .velemenyek-form .form-row-actions button[type="submit"] {
        transition: none !important;
    }
}
