/* Cibula Fest Dotazník - Frontend Styles */

/* Override theme checkbox/radio checked styles */
.cfq-container input[type="checkbox"]:checked::after,
.cfq-container input[type="radio"]:checked::after {
    background-color: transparent !important;
    background: none !important;
}

/* Override theme focus styles */
.cfq-container input[type="date"]:focus,
.cfq-container input[type="email"]:focus,
.cfq-container input[type="number"]:focus,
.cfq-container input[type="password"]:focus,
.cfq-container input[type="search"]:focus,
.cfq-container input[type="tel"]:focus,
.cfq-container input[type="text"]:focus,
.cfq-container input[type="url"]:focus,
.cfq-container select:focus,
.cfq-container textarea:focus {
    outline: none !important;
    box-shadow: none !important;
    border-color: var(--cfq-primary, #fe6c21) !important;
    color: #000 !important;
}

/* Hide native checkbox/radio - use custom .cfq-option-mark instead */
.cfq-container .cfq-option input[type="checkbox"],
.cfq-container .cfq-option input[type="radio"] {
    -webkit-appearance: none !important;
    appearance: none !important;
    background: none !important;
    box-shadow: none !important;
    border: none !important;
    width: 0 !important;
    height: 0 !important;
    min-width: 0 !important;
    min-height: 0 !important;
    position: absolute !important;
    opacity: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
}

.cfq-container .cfq-option input[type="checkbox"]::before,
.cfq-container .cfq-option input[type="checkbox"]::after,
.cfq-container .cfq-option input[type="radio"]::before,
.cfq-container .cfq-option input[type="radio"]::after {
    content: none !important;
    display: none !important;
}

body.artists-fullscreen {
    margin: 0;
    padding: 0;
    background: #fff;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Container */
.cfq-container {
    width: 100%;
    max-width: 700px;
    margin: 0 auto;
    padding: 30px 20px;
    background: transparent;
    min-height: 100vh;
    min-height: 100dvh;
    font-family: var(--cfq-font, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif);
    color: var(--cfq-text, #373737);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.cfq-container:has(.cfq-step[data-step="0"].active) {
    max-width: 1000px;
}

.cfq-container *, .cfq-container *::before, .cfq-container *::after {
    box-sizing: border-box;
}

/* Form */
#cfq-form {
}

/* Progress Bar - fixed at top */
.cfq-progress-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    padding: 12px 20px 0;
    z-index: 9999;
    background: #fff;
}

.cfq-progress-bar {
    width: 100%;
    height: 6px;
    background: var(--cfq-border, #e5e7eb);
    border-radius: 3px;
    overflow: hidden;
}

.cfq-progress-fill {
    height: 100%;
    background: var(--cfq-primary, #fe6c21);
    border-radius: 3px;
}

.cfq-progress-text {
    text-align: center;
    font-size: 13px;
    color: var(--cfq-text, #999);
    opacity: 0.6;
    margin-top: 8px;
    font-weight: 600;
}

/* Logo */
.cfq-logo {
    max-width: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

/* Steps - simple show/hide, no animations */
.cfq-step {
    display: none;
    width: 100%;
}

.cfq-step.active {
    display: block;
}

/* Step Header */
.cfq-step-header {
    text-align: center;
    margin-bottom: 10px;
}

/* Question Card */
.cfq-question-card {
    padding: 28px 24px;
    background: var(--cfq-bg, #fff);
    border: 1px solid var(--cfq-border, #e5e7eb);
    border-radius: 16px;
    flex: 1;
}

.cfq-question-label {
    display: block;
    font-size: clamp(18px, 3vw, 22px);
    font-weight: 700;
    color: var(--cfq-text, #373737);
    margin-bottom: 8px;
    line-height: 1.4;
}

.cfq-required {
    color: #DC2626;
    margin-left: 2px;
}

.cfq-question-sublabel {
    font-size: 14px;
    color: var(--cfq-primary, #fe6c21);
    opacity: 1;
    margin: 0 0 16px;
    font-weight: 500;
}

/* Options (Radio/Checkbox) */
.cfq-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 8px;
}

.cfq-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: var(--cfq-accent, #f9fafb);
    border: 2px solid transparent;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 400;
    font-size: clamp(14px, 2.5vw, 16px);
    line-height: 1.4;
}

.cfq-option:hover {
    background: var(--cfq-bg, #fff);
    border-color: var(--cfq-primary, #fe6c21);
}

.cfq-option input[type="radio"],
.cfq-option input[type="checkbox"] {
    display: none;
}

.cfq-option-mark {
    width: 24px;
    height: 24px;
    min-width: 24px;
    border: 2px solid var(--cfq-border, #d1d5db);
    border-radius: 50%;
    background: white;
    position: relative;
    flex-shrink: 0;
}

.cfq-checkbox-mark {
    border-radius: 6px;
}

.cfq-option input:checked ~ .cfq-option-mark {
    background: var(--cfq-primary, #fe6c21);
    border-color: var(--cfq-primary, #fe6c21);
}

.cfq-option input:checked ~ .cfq-option-mark::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
}

.cfq-option input[type="checkbox"]:checked ~ .cfq-checkbox-mark::after {
    content: '\2713';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: auto;
    height: auto;
    background: none;
    border-radius: 0;
    color: white;
    font-size: 14px;
    font-weight: bold;
}

.cfq-option input:checked ~ .cfq-option-text {
    font-weight: 600;
    color: var(--cfq-primary, #fe6c21);
}

/* Checked option background */
.cfq-option:has(input:checked) {
    background: var(--cfq-bg, #fff);
    border-color: var(--cfq-primary, #fe6c21);
}

/* Other option */
.cfq-option-other {
    flex-wrap: wrap;
}

.cfq-other-input {
    flex: 1;
    min-width: 120px;
    padding: 10px 14px;
    border: 1px solid var(--cfq-border, #d1d5db);
    border-radius: 8px;
    font-size: 15px;
    background: white;
    color: #000 !important;
    -webkit-text-fill-color: #000;
}

.cfq-other-input:focus {
    outline: none;
    border-color: var(--cfq-primary, #fe6c21);
}

.cfq-other-input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    -webkit-text-fill-color: #999;
    color: #999 !important;
}

/* Select */
.cfq-select {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid var(--cfq-border, #e5e7eb);
    border-radius: 12px;
    background: white;
    color: #000;
    font-size: clamp(14px, 2.5vw, 16px);
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M6 8L1 3h10z' fill='%23666'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
    margin-top: 8px;
}

.cfq-select:focus {
    outline: none;
    border-color: var(--cfq-primary, #fe6c21);
}

/* Text Input */
.cfq-text-input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid var(--cfq-border, #e5e7eb);
    border-radius: 12px;
    background: white;
    color: #000;
    font-size: clamp(14px, 2.5vw, 16px);
    margin-top: 8px;
}

.cfq-text-input:focus {
    outline: none;
    border-color: var(--cfq-primary, #fe6c21);
}

.cfq-text-input::placeholder {
    color: #000;
    opacity: 1;
}

/* Verification Code Inputs */
.cfq-code-digit {
    width: 60px;
    height: 72px;
    text-align: center;
    font-size: 32px;
    font-weight: 700;
    color: #000;
    border: 2px solid var(--cfq-border, #e5e7eb);
    border-radius: 12px;
    background: white;
    -webkit-text-fill-color: #000;
}

.cfq-code-digit:focus {
    outline: none;
    border-color: var(--cfq-primary, #fe6c21);
}

@media (max-width: 480px) {
    .cfq-code-digit {
        width: 50px;
        height: 60px;
        font-size: 26px;
    }
}

/* Rating Stars */
.cfq-rating {
    display: flex;
    gap: 12px;
    justify-content: center;
    padding: 20px 0;
}

.cfq-star {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--cfq-border, #d1d5db);
    padding: 4px;
    border-radius: 4px;
}

.cfq-star:hover,
.cfq-star.active {
    color: #fbbf24;
}

.cfq-star svg {
    display: block;
}

/* Error Message */
.cfq-error-msg {
    color: #DC2626;
    font-size: 14px;
    margin-top: 12px;
    font-weight: 600;
    text-align: center;
}

/* Form Message */
.cfq-message {
    max-width: 600px;
    width: 100%;
    margin: 20px auto;
    padding: 16px 20px;
    border-radius: 10px;
    text-align: center;
    font-size: 15px;
    font-weight: 600;
}

.cfq-message.success {
    background: var(--cfq-primary, #fe6c21);
    color: white;
}

.cfq-message.error {
    background: rgba(220, 38, 38, 0.1);
    border: 2px solid #DC2626;
    color: #DC2626;
}

/* Email Step Title */
.cfq-step-title {
    font-size: clamp(22px, 4vw, 32px);
    font-weight: 700;
    color: var(--cfq-text, #373737);
    text-align: center;
    margin: 0 0 30px;
}

.cfq-form-group {
    max-width: 500px;
    width: 100%;
    margin: 0 auto 25px;
}

.cfq-form-group label:not(.cfq-gdpr-label) {
    display: block;
    font-size: 15px;
    font-weight: 600;
    color: var(--cfq-text, #373737);
    margin-bottom: 8px;
}

.cfq-form-group input[type="email"],
.cfq-form-group input[type="text"] {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid var(--cfq-border, #e5e7eb);
    border-radius: 12px;
    background: white;
    color: #000;
    font-size: 15px;
}

.cfq-form-group input::placeholder {
    color: #000;
    opacity: 1;
}

.cfq-form-group input:focus {
    outline: none;
    border-color: var(--cfq-primary, #fe6c21);
}

.cfq-field-note {
    font-size: 12px;
    color: #6b7280;
    margin: 6px 0 0;
}

/* GDPR */
.cfq-gdpr {
    margin-top: 30px;
}

.cfq-gdpr-label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    font-size: 13px;
    line-height: 1.5;
    font-weight: 400;
}

.cfq-gdpr-label input[type="checkbox"] {
    width: 24px;
    height: 24px;
    min-width: 24px;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    border: 2px solid var(--cfq-border, #d1d5db);
    border-radius: 4px;
    background: white;
    position: relative;
    flex-shrink: 0;
    margin: 0;
}

.cfq-gdpr-label input[type="checkbox"]:checked {
    background: var(--cfq-primary, #fe6c21);
    border-color: var(--cfq-primary, #fe6c21);
}

.cfq-gdpr-label input[type="checkbox"]:checked::after {
    content: '';
    position: absolute;
    top: 4px;
    left: 8px;
    width: 6px;
    height: 12px;
    border: solid white;
    border-width: 0 2.5px 2.5px 0;
    transform: rotate(45deg);
}

.cfq-gdpr-label a {
    color: var(--cfq-primary, #fe6c21);
    text-decoration: underline;
    font-weight: 600;
}

.cfq-gdpr-full {
    margin-top: 12px;
    padding: 16px;
    background: var(--cfq-accent, #f9fafb);
    border: 1px solid var(--cfq-border, #e5e7eb);
    border-radius: 8px;
    font-size: 12px;
    line-height: 1.6;
    white-space: pre-line;
    color: var(--cfq-text, #666);
    max-height: 300px;
    overflow-y: auto;
}

/* Buttons */
.cfq-buttons {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 30px;
    padding: 0 10px;
}

.cfq-btn {
    padding: 14px 36px;
    border: none;
    border-radius: 12px;
    font-size: clamp(14px, 2.5vw, 16px);
    font-weight: 700;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    min-width: 150px;
    text-align: center;
    font-family: inherit;
}

.cfq-btn-primary {
    background: var(--cfq-primary, #fe6c21);
    color: white;
}

.cfq-btn-primary:hover:not(:disabled) {
    opacity: 0.9;
}

.cfq-btn-secondary {
    background: transparent;
    border: 2px solid var(--cfq-border, #e5e7eb);
    color: var(--cfq-text, #373737);
}

.cfq-btn-secondary:hover {
    background: var(--cfq-accent, #f9fafb);
    border-color: var(--cfq-text, #373737);
}

.cfq-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Shake animation for wrong code */
@keyframes cfqShake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-10px); }
    40% { transform: translateX(10px); }
    60% { transform: translateX(-6px); }
    80% { transform: translateX(6px); }
}

/* Responsive - Tablet */
@media (max-width: 768px) {
    .cfq-container {
        padding: 20px 10px;
    }

    .cfq-question-card {
        padding: 20px 16px;
    }

    .cfq-option {
        padding: 12px 14px;
        gap: 10px;
    }

    .cfq-option-mark {
        width: 22px;
        height: 22px;
        min-width: 22px;
    }

    .cfq-star svg {
        width: 40px;
        height: 40px;
    }

    .cfq-btn {
        min-width: 0;
        flex: 1;
    }

    .cfq-logo {
        max-height: 50px !important;
    }
}

/* Responsive - Small Mobile */
@media (max-width: 480px) {
    .cfq-container {
        padding: 15px 8px;
    }

    .cfq-question-card {
        padding: 18px 14px;
    }

    .cfq-option {
        padding: 10px 12px;
        gap: 8px;
        font-size: 14px;
    }

    .cfq-star svg {
        width: 36px;
        height: 36px;
    }

    .cfq-logo {
        max-height: 40px !important;
    }
}
