/* Dotaznik — custom styles nad Tailwindom */

/* ── Zamedzi horizontalnemu scrollu na mobile ─────────────────────────────── */
html, body {
    overflow-x: hidden;
    max-width: 100%;
}

/* ── Required star (corner) ──────────────────────────────────────────────── */
.required-star {
    position: absolute;
    top: -11px;
    right: -9px;
    font-size: 1.6rem;
    color: #4BA82E;
    transform: rotate(18deg);
    filter: drop-shadow(0 1px 3px rgba(75, 168, 46, 0.35));
    pointer-events: none;
    user-select: none;
    line-height: 1;
}

/* ── Rating star fill ────────────────────────────────────────────────────── */
.rating-star {
    background: linear-gradient(to top, #D2D2D2 100%, #D2D2D2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    transition: none;
}

/* ── Rating slider ────────────────────────────────────────────────────────── */
.rating-range {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    max-width: 100%;
    height: 7px;
    border-radius: 9999px;
    outline: none;
    cursor: pointer;
    background: #E5E7EB;
    transition: background 0.05s;
    touch-action: pan-y;
    box-sizing: border-box;
}

.rating-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid #4BA82E;
    box-shadow: 0 2px 8px rgba(75, 168, 46, 0.3);
    cursor: grab;
    transition: transform 0.1s, box-shadow 0.1s;
}

.rating-range::-webkit-slider-thumb:hover {
    transform: scale(1.12);
    box-shadow: 0 3px 12px rgba(75, 168, 46, 0.4);
}

.rating-range:active::-webkit-slider-thumb {
    cursor: grabbing;
    transform: scale(1.08);
}

.rating-range::-moz-range-thumb {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid #4BA82E;
    box-shadow: 0 2px 8px rgba(75, 168, 46, 0.3);
    cursor: grab;
}

.rating-range::-moz-range-track {
    height: 7px;
    border-radius: 9999px;
    background: transparent;
}

/* ── Radio karty ──────────────────────────────────────────────────────────── */
.radio-card {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 10px 8px;
    border-radius: 8px;
    border: 1.5px solid #D2D2D2;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 500;
    color: #474747;
    background: #fff;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
    min-height: 44px;
}

.radio-card:hover {
    border-color: #4BA82E;
    background: #F2F9F0;
    color: #398E1E;
}

.radio-card.selected {
    border-color: #4BA82E;
    background: #F2F9F0;
    color: #398E1E;
    font-weight: 700;
}

.radio-card:focus-within {
    outline: 2px solid #4BA82E;
    outline-offset: 2px;
}

/* ── Checkbox karty ───────────────────────────────────────────────────────── */
.checkbox-card {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1.5px solid #D2D2D2;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 500;
    color: #474747;
    background: #fff;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
    min-height: 44px;
    user-select: none;
}

.checkbox-card:hover {
    border-color: #4BA82E;
    background: #F2F9F0;
    color: #398E1E;
}

.checkbox-card.selected {
    border-color: #4BA82E;
    background: #F2F9F0;
    color: #398E1E;
    font-weight: 600;
}

.checkbox-check {
    flex-shrink: 0;
    display: block;
    width: 18px;
    height: 18px;
    border-radius: 4px;
    border: 2px solid #D2D2D2;
    background: #fff;
    position: relative;
    transition: border-color 0.15s, background 0.15s;
}

.checkbox-card.selected .checkbox-check {
    border-color: #4BA82E;
    background: #4BA82E;
}

.checkbox-card.selected .checkbox-check::after {
    content: '';
    position: absolute;
    left: 3px;
    top: 1px;
    width: 8px;
    height: 5px;
    border-left: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(-45deg);
}
