:root {
    --ta-green: #00aa6c;
    --ta-green-dark: #00875a;
    --ta-green-light: #e6f7f0;
    --ta-dark: #121212;
    --ta-text: #2c2c2c;
    --ta-muted: #545454;
    --ta-border: #e0e0e0;
    --ta-bg-light: #f7f7f7;
    --ta-bubble-green: #00aa6c;
    --ta-bubble-empty: #dcdcdc;
    --ta-font: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --ta-radius: 10px;
    --ta-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
}

/* Base Widget Reset */
.ta-widget-root {
    font-family: var(--ta-font);
    color: var(--ta-text);
    box-sizing: border-box;
    line-height: 1.45;
}
.ta-widget-root *, .ta-widget-root *::before, .ta-widget-root *::after {
    box-sizing: border-box;
}

/* TripAdvisor Rating Bubbles */
.ta-bubbles {
    display: inline-flex;
    align-items: center;
    gap: 3.5px;
}
.ta-bubble {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background-color: var(--ta-bubble-green);
    display: inline-block;
}
.ta-bubble.half {
    background: linear-gradient(90deg, var(--ta-bubble-green) 50%, var(--ta-bubble-empty) 50%);
}
.ta-bubble.empty {
    background-color: var(--ta-bubble-empty);
}

/* Mini Tripadvisor Owl Logo */
.ta-logo-svg {
    height: 22px;
    vertical-align: middle;
    display: inline-block;
}

/* ======================================================== */
/* LAYOUT 1: CAROUSEL / SLIDER (Ideale per Homepage)        */
/* ======================================================== */
.ta-carousel-container {
    background: #ffffff;
    border: 1px solid var(--ta-border);
    border-radius: var(--ta-radius);
    padding: 24px;
    box-shadow: var(--ta-shadow);
    max-width: 960px;
    margin: 0 auto;
}

.ta-widget-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--ta-border);
    padding-bottom: 18px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 14px;
}

.ta-brand-area {
    display: flex;
    align-items: center;
    gap: 12px;
}

.ta-logo-circle {
    width: 44px;
    height: 44px;
    background: #ffffff;
    border: 1.5px solid var(--ta-border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}

.ta-rest-name {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--ta-dark);
    margin: 0;
    line-height: 1.2;
}

.ta-rest-ranking {
    font-size: 0.8rem;
    color: var(--ta-muted);
    margin-top: 3px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.ta-badge-choice {
    background: #fff8e6;
    color: #b78103;
    border: 1px solid #ffd666;
    padding: 2px 7px;
    border-radius: 4px;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
}

.ta-header-score {
    display: flex;
    align-items: center;
    gap: 12px;
}

.ta-score-number {
    font-size: 2rem;
    font-weight: 900;
    color: var(--ta-dark);
    line-height: 1;
}

.ta-subscores-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    background: var(--ta-bg-light);
    border-radius: 8px;
    padding: 10px 14px;
    margin-bottom: 20px;
    font-size: 0.8rem;
}
@media (max-width: 600px) {
    .ta-subscores-grid { grid-template-columns: repeat(2, 1fr); }
}

.ta-subscore-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.ta-subscore-label {
    font-size: 0.72rem;
    color: var(--ta-muted);
    font-weight: 600;
}
.ta-subscore-val {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 700;
    font-size: 0.82rem;
}

/* Slider Track */
.ta-slider-wrapper {
    position: relative;
    overflow: hidden;
    padding: 4px 2px;
}

.ta-slides-track {
    display: flex;
    gap: 16px;
    transition: transform 0.35s ease-in-out;
}

.ta-card-slide {
    flex: 0 0 calc(33.333% - 11px);
    background: #ffffff;
    border: 1px solid var(--ta-border);
    border-radius: 8px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 240px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.ta-card-slide:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(0,0,0,0.06);
    border-color: #cbd5e1;
}

@media (max-width: 860px) {
    .ta-card-slide { flex: 0 0 calc(50% - 8px); }
}
@media (max-width: 540px) {
    .ta-card-slide { flex: 0 0 100%; }
}

.ta-card-user {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.ta-user-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #e2e8f0;
    color: #475569;
    font-weight: 800;
    font-size: 0.78rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ta-user-info {
    font-size: 0.8rem;
}
.ta-user-name {
    font-weight: 700;
    color: var(--ta-dark);
}
.ta-user-origin {
    font-size: 0.72rem;
    color: var(--ta-muted);
}

.ta-card-bubbles-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.ta-rev-date {
    font-size: 0.72rem;
    color: var(--ta-muted);
}

.ta-rev-title {
    font-size: 0.88rem;
    font-weight: 800;
    color: var(--ta-dark);
    margin: 0 0 6px 0;
    line-height: 1.3;
}

.ta-rev-body {
    font-size: 0.82rem;
    color: #374151;
    line-height: 1.45;
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ta-owner-response {
    background: var(--ta-bg-light);
    border-left: 3px solid var(--ta-green);
    border-radius: 0 4px 4px 0;
    padding: 8px 10px;
    font-size: 0.75rem;
    color: #4b5563;
    margin-top: auto;
}
.ta-owner-title {
    font-weight: 700;
    color: var(--ta-green-dark);
    margin-bottom: 2px;
}

/* Slider Controls */
.ta-slider-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 18px;
    padding-top: 12px;
    border-top: 1px solid var(--ta-border);
}

.ta-nav-buttons {
    display: flex;
    gap: 8px;
}

.ta-slider-btn {
    background: #ffffff;
    border: 1px solid var(--ta-border);
    color: var(--ta-dark);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}
.ta-slider-btn:hover {
    background: var(--ta-bg-light);
    border-color: var(--ta-dark);
}

.ta-cta-link {
    color: var(--ta-green-dark);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
.ta-cta-link:hover {
    text-decoration: underline;
}

/* ======================================================== */
/* LAYOUT 2: COMPACT BADGE (Ideale per Header o Footer)     */
/* ======================================================== */
.ta-compact-badge {
    background: #ffffff;
    border: 1px solid var(--ta-border);
    border-radius: 8px;
    padding: 10px 14px;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    text-decoration: none;
    color: var(--ta-dark);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.ta-compact-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(0,0,0,0.1);
}

.ta-badge-icon {
    width: 32px;
    height: 32px;
}

.ta-badge-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ta-badge-name {
    font-size: 0.8rem;
    font-weight: 800;
    line-height: 1.2;
}

.ta-badge-rating-row {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    color: var(--ta-muted);
}

/* ======================================================== */
/* LAYOUT 3: FLOATING STICKY PILL                           */
/* ======================================================== */
.ta-floating-pill {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: #ffffff;
    border: 1.5px solid var(--ta-green);
    border-radius: 999px;
    padding: 8px 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
    cursor: pointer;
    z-index: 9999;
    text-decoration: none;
    color: var(--ta-dark);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.ta-floating-pill:hover {
    transform: scale(1.04);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.24);
}
.ta-pill-score {
    font-weight: 800;
    font-size: 0.85rem;
}

/* ======================================================== */
/* LAYOUT 5: SIMPLE SCORE CARD (Look Identico a Screenshot) */
/* ======================================================== */
.ta-simple-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    padding: 22px 28px 20px 28px;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    text-decoration: none;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    cursor: pointer;
    min-width: 200px;
    max-width: 250px;
}

.ta-simple-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    border-color: #cbd5e1;
}

.ta-simple-logo-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
}

.ta-simple-score {
    font-size: 3.2rem;
    font-weight: 900;
    color: #003822;
    line-height: 1;
    letter-spacing: -1.5px;
    margin-bottom: 6px;
    font-family: var(--ta-font);
}

.ta-simple-label {
    font-size: 1.15rem;
    font-weight: 800;
    color: #004d32;
    margin-bottom: 12px;
    letter-spacing: -0.2px;
}

.ta-simple-bubbles-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.ta-simple-bubbles-row .ta-bubble {
    width: 16px;
    height: 16px;
}

.ta-simple-count {
    font-size: 0.95rem;
    font-weight: 600;
    color: #004d32;
    margin-left: 2px;
}

