/* ── Write a Review toggle button ───────────────────── */
.tgit-review-toggle {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    margin-top: 2rem;
    padding: .75rem 1.5rem;
    background: transparent;
    border: 1.5px solid #D4961E;
    color: #D4961E;
    border-radius: 6px;
    font-size: .9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: background .2s, color .2s;
}

.tgit-review-toggle:hover,
.tgit-review-toggle[aria-expanded="true"] {
    background: #D4961E;
    color: #fff;
}

.tgit-toggle-icon {
    transition: transform .25s ease;
}

.tgit-review-toggle[aria-expanded="true"] .tgit-toggle-icon {
    transform: rotate(180deg);
}

/* ── Form wrapper / slide-down ───────────────────────── */
.tgit-review-form-inner {
    margin-top: 1.5rem;
    border: 1px solid #E8E0D5;
    border-radius: 10px;
    padding: 2rem;
    background: #FDFAF6;
    animation: tgit-slide-in .3s ease;
}

@keyframes tgit-slide-in {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ── Star picker ─────────────────────────────────────── */
.tgit-star-fieldset {
    border: none;
    padding: 0;
    margin: 0 0 1.5rem;
}

.tgit-star-fieldset legend {
    font-size: .875rem;
    font-weight: 600;
    color: #6B5F52;
    margin-bottom: .6rem;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.tgit-star-picker {
    display: flex;
    flex-direction: row-reverse;
    gap: .2rem;
    width: fit-content;
}

.tgit-star-picker label {
    font-size: 2rem;
    color: #D9CFC4;
    cursor: pointer;
    transition: color .15s, transform .15s;
    line-height: 1;
}

.tgit-star-picker label:hover,
.tgit-star-picker label:hover~label {
    color: #D4961E;
    transform: scale(1.15);
}

.tgit-star-picker input:checked~label {
    color: #D4961E;
}

.tgit-star-picker input:checked+label {
    transform: scale(1.2);
}

.tgit-star-hint {
    font-size: .8125rem;
    color: #D4961E;
    min-height: 1.2em;
    margin-top: .35rem;
}

/* ── Form fields ─────────────────────────────────────── */
.tgit-field {
    display: flex;
    flex-direction: column;
    gap: .4rem;
    margin-bottom: 1.25rem;
}

.tgit-field label {
    font-size: .875rem;
    font-weight: 600;
    color: #6B5F52;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.tgit-field-optional {
    font-weight: 400;
    text-transform: none;
    letter-spacing: 0;
    opacity: .6;
    font-size: .8rem;
}

.tgit-field input[type="text"],
.tgit-field textarea,
.tgit-field select {
    background: #FFFFFF;
    border: 1px solid #E0D6CA;
    border-radius: 6px;
    color: #2C2015;
    padding: .7rem 1rem;
    font-size: .9375rem;
    transition: border-color .2s, box-shadow .2s;
    resize: vertical;
}

.tgit-field input::placeholder,
.tgit-field textarea::placeholder {
    color: #B5A898;
}

.tgit-field input:focus,
.tgit-field textarea:focus,
.tgit-field select:focus {
    outline: none;
    border-color: #D4961E;
    box-shadow: 0 0 0 3px rgba(212, 150, 30, .12);
}

/* Two-column row */
.tgit-fields-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

@media (max-width: 480px) {
    .tgit-fields-row {
        grid-template-columns: 1fr;
    }
}

/* Char count */
.tgit-char-count {
    font-size: .8rem;
    color: #9C8E82;
    text-align: right;
}

/* ── Footer / submit ─────────────────────────────────── */
.tgit-form-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 1.75rem;
    padding-top: 1.25rem;
    border-top: 1px solid #EDE6DC;
}

.tgit-form-note {
    font-size: .8125rem;
    color: #9C8E82;
    display: flex;
    align-items: center;
    gap: .35rem;
}

.tgit-submit-btn {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: .75rem 1.75rem;
    background: #D4961E;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: .9375rem;
    font-weight: 700;
    cursor: pointer;
    transition: background .2s, transform .15s;
}

.tgit-submit-btn:hover {
    background: #b87d18;
    transform: translateY(-1px);
}

.tgit-submit-btn:disabled {
    opacity: .6;
    cursor: not-allowed;
    transform: none;
}

/* ── Notes / success / error ─────────────────────────── */
.tgit-review-note {
    margin-top: 1.5rem;
    color: #9C8E82;
    font-size: .9rem;
    display: flex;
    align-items: center;
    gap: .4rem;
}

.tgit-review-success {
    background: #F0FAF4;
    border: 1px solid #A8D5B5;
    color: #2D7A4F;
    border-radius: 6px;
    padding: .9rem 1.2rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: .5rem;
    font-size: .9rem;
}

/* ── Accessibility util ──────────────────────────────── */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.req {
    color: #D4961E;
}

/* Ensure the star icons have content and are visible */
.tgit-star-picker i.ti-star-filled::before {
    content: "\ea43";
    /* Tabler Icon star-filled code */
    display: inline-block;
    font-family: "tabler-icons" !important;
}

/* Base style for the stars */
.tgit-star-picker label {
    cursor: pointer;
    color: #d9cfc4;
    /* Default empty star color */
    transition: color 0.2s;
}

/* Hover effect: Highlight stars from right to left (due to row-reverse) */
.tgit-star-picker label:hover,
.tgit-star-picker label:hover~label,
.tgit-star-picker input:checked~label {
    color: #ffb400;
    /* Gold color for selected/hovered stars */
}

/* Reviews */
.reviews-summary {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 2rem;
    align-items: center;
    background: var(--white);
    border: 1px solid var(--border-2);
    border-radius: var(--radius-lg);
    padding: 1.75rem 2rem;
    margin-bottom: 2rem
}

@media(max-width:600px) {
    .reviews-summary {
        grid-template-columns: 1fr;
        gap: 1.25rem
    }
}

.review-score-num {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--charcoal);
    line-height: 1;
    text-align: center
}

.review-score-sub {
    font-size: .75rem;
    color: var(--text-muted);
    text-align: center;
    margin-top: .25rem
}

.rating-bars {
    display: flex;
    flex-direction: column;
    gap: .5rem
}

.rb-row {
    display: flex;
    align-items: center;
    gap: .75rem;
    font-size: .75rem
}

.rb-lbl {
    color: var(--text-muted);
    min-width: 36px
}

.rb-track {
    flex: 1;
    height: 6px;
    background: var(--cream-3);
    border-radius: 4px;
    overflow: hidden
}

.rb-fill {
    height: 100%;
    background: linear-gradient(90deg, #D4961E, #E8B040);
    border-radius: 4px
}

.rb-pct {
    color: var(--text-2);
    font-weight: 600;
    min-width: 30px;
    text-align: right
}

.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem
}

.review-card {
    background: var(--white);
    border: 1px solid var(--border-2);
    border-radius: var(--radius-lg);
    padding: 1.375rem;
    transition: border-color var(--tr)
}

.review-card:hover {
    border-color: var(--border)
}

.review-hdr {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: .75rem
}

.reviewer-info {
    display: flex;
    align-items: center;
    gap: .75rem
}

.rev-initial {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: var(--gold-bg);
    border: 2px solid var(--gold-border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 1rem;
    color: var(--gold-hover);
    flex-shrink: 0
}

.rev-name {
    font-size: .9375rem;
    font-weight: 600;
    color: var(--charcoal)
}

.rev-meta {
    font-size: .75rem;
    color: var(--text-muted);
    margin-top: .125rem
}

.rev-date {
    font-size: .75rem;
    color: var(--text-muted)
}

.review-text {
    font-size: .875rem;
    color: var(--text-2);
    line-height: 1.65
}

.rev-verified {
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    font-size: .6875rem;
    color: #2E7D32;
    font-weight: 600;
    margin-top: .625rem
}