/* ── Reset & Base ── */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

.vkjp-survey-body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: #0d1117;
    color: #e6edf3;
    min-height: 100vh;
    overflow: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ── Progress Bar ── */
.vkjp-progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: rgba(255,255,255,0.08);
    z-index: 100;
}

.vkjp-progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #17b321, #2ecc40);
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 0 2px 2px 0;
}

/* ── Survey Container ── */
.vkjp-survey {
    position: relative;
    width: 100%;
    height: 100vh;
}

/* ── Slides ── */
.vkjp-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
    padding: 20px;
}

.vkjp-slide--active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
    z-index: 10;
}

.vkjp-slide--exit-up {
    opacity: 0;
    transform: translateY(-40px);
    pointer-events: none;
}

.vkjp-slide--exit-down {
    opacity: 0;
    transform: translateY(40px);
    pointer-events: none;
}

.vkjp-slide-inner {
    max-width: 640px;
    width: 100%;
    text-align: left;
}

/* ── Intro & Thankyou ── */
.vkjp-slide--intro .vkjp-slide-inner,
.vkjp-slide--thankyou .vkjp-slide-inner {
    text-align: center;
}

.vkjp-slide--thankyou {
    height: auto;
    min-height: 100vh;
    overflow-y: auto;
}

.vkjp-intro-logo {
    display: inline-block;
    margin-bottom: 28px;
}

.vkjp-intro-logo img {
    max-height: 60px;
    width: auto;
}

.vkjp-checkmark {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(23, 179, 33, 0.15);
    color: #17b321;
    font-size: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 32px;
}

/* ── Typography ── */
.vkjp-title {
    font-size: 32px;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 12px;
    color: #ffffff;
}

.vkjp-subtitle {
    font-size: 17px;
    line-height: 1.6;
    color: #8b949e;
    margin-bottom: 32px;
}

.vkjp-question-number {
    font-size: 13px;
    font-weight: 600;
    color: #17b321;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.vkjp-question-number svg {
    width: 16px;
    height: 16px;
}

.vkjp-question-label {
    font-size: 26px;
    font-weight: 600;
    line-height: 1.35;
    margin-bottom: 8px;
    color: #ffffff;
}

.vkjp-question-sublabel {
    font-size: 15px;
    color: #8b949e;
    margin-bottom: 28px;
    line-height: 1.5;
}

/* ── Buttons ── */
.vkjp-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 14px 32px;
    border: none;
    border-radius: 8px;
    font-family: inherit;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.vkjp-btn--primary {
    background: #17b321;
    color: #ffffff;
}

.vkjp-btn--primary:hover:not(:disabled) {
    background: #1fcf2b;
    transform: translateY(-1px);
}

.vkjp-btn--primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.vkjp-btn--secondary {
    background: rgba(255,255,255,0.08);
    color: #e6edf3;
    border: 1px solid rgba(255,255,255,0.12);
}

.vkjp-btn--secondary:hover {
    background: rgba(255,255,255,0.12);
}

.vkjp-btn--submit {
    background: #17b321;
    color: #ffffff;
    padding: 16px 40px;
    font-size: 17px;
}

.vkjp-btn--submit:hover {
    background: #1fcf2b;
    transform: translateY(-1px);
}

.vkjp-btn--submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.vkjp-btn-hint {
    font-size: 13px;
    font-weight: 400;
    opacity: 0.6;
}

.vkjp-btn-hint kbd {
    display: inline-block;
    padding: 2px 6px;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 3px;
    font-family: inherit;
    font-size: 12px;
    background: rgba(255,255,255,0.05);
}

/* ── Input Fields ── */
.vkjp-input-wrap {
    margin-bottom: 24px;
}

.vkjp-input {
    width: 100%;
    padding: 16px 0;
    background: transparent;
    border: none;
    border-bottom: 2px solid rgba(255,255,255,0.15);
    color: #ffffff;
    font-family: inherit;
    font-size: 22px;
    font-weight: 500;
    outline: none;
    transition: border-color 0.3s ease;
}

.vkjp-input::placeholder {
    color: rgba(255,255,255,0.2);
}

.vkjp-input:focus {
    border-bottom-color: #17b321;
}

.vkjp-input--textarea {
    resize: vertical;
    min-height: 100px;
    border: 2px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    padding: 16px;
    font-size: 18px;
}

.vkjp-input--textarea:focus {
    border-color: #17b321;
}

.vkjp-input-error {
    color: #f85149;
    font-size: 14px;
    margin-top: 8px;
    display: none;
}

.vkjp-input-error.vkjp-visible {
    display: block;
}

/* ── Radio & Checkbox Options ── */
.vkjp-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 24px;
}

.vkjp-option {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
    position: relative;
}

.vkjp-option:hover {
    border-color: rgba(23, 179, 33, 0.4);
    background: rgba(23, 179, 33, 0.05);
}

.vkjp-option--selected {
    border-color: #17b321;
    background: rgba(23, 179, 33, 0.1);
}

.vkjp-option--disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.vkjp-option--disabled:hover {
    border-color: rgba(255,255,255,0.1);
    background: transparent;
}

.vkjp-option-key {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 28px;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #8b949e;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.vkjp-option--selected .vkjp-option-key {
    background: #17b321;
    border-color: #17b321;
    color: #ffffff;
}

.vkjp-option-label {
    font-size: 16px;
    line-height: 1.4;
    color: #e6edf3;
}

/* Checkbox indicator */
.vkjp-option--checkbox .vkjp-option-key {
    border-radius: 4px;
}

.vkjp-option--checkbox.vkjp-option--selected .vkjp-option-key::after {
    content: '\2713';
    font-size: 14px;
}

/* ── Navigation ── */
.vkjp-nav {
    position: fixed;
    bottom: 32px;
    right: 32px;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 50;
}

.vkjp-nav-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 8px;
    background: rgba(13, 17, 23, 0.8);
    backdrop-filter: blur(10px);
    color: #e6edf3;
    cursor: pointer;
    transition: all 0.2s ease;
}

.vkjp-nav-btn:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.2);
}

.vkjp-nav-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.vkjp-nav-counter {
    font-size: 13px;
    color: #8b949e;
    margin-left: 8px;
}

/* ── Keyboard Hints ── */
.vkjp-keyboard-hints {
    position: fixed;
    bottom: 32px;
    left: 32px;
    display: flex;
    gap: 16px;
    z-index: 50;
}

.vkjp-keyboard-hints span {
    font-size: 13px;
    color: #484f58;
}

.vkjp-keyboard-hints kbd {
    display: inline-block;
    padding: 2px 6px;
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 3px;
    font-family: inherit;
    font-size: 12px;
    color: #8b949e;
    margin-right: 4px;
    background: rgba(255,255,255,0.04);
}

/* ── Loading spinner ── */
.vkjp-loading {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255,255,255,0.2);
    border-top-color: #17b321;
    border-radius: 50%;
    animation: vkjp-spin 0.6s linear infinite;
}

@keyframes vkjp-spin {
    to { transform: rotate(360deg); }
}

/* ── Consent & Privacy Policy ── */
.vkjp-consent {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    color: #8b949e;
    cursor: pointer;
    margin-bottom: 24px;
    user-select: none;
    justify-content: center;
}

.vkjp-consent input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #17b321;
    cursor: pointer;
    flex-shrink: 0;
}

.open-privacy-policy {
    color: #17b321;
    text-decoration: underline;
    cursor: pointer;
}

.open-privacy-policy:hover {
    color: #1fcf2b;
}

.show-privacy-policy {
    display: none;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 24px;
    max-height: 200px;
    overflow-y: auto;
}

.show-privacy-policy.vkjp-visible {
    display: block;
}

.show-privacy-policy small {
    font-size: 13px;
    line-height: 1.6;
    color: #8b949e;
}

/* ── Biotype Result (Thank You Screen) ── */
#vkjp-biotype-result {
    margin: 24px 0;
    text-align: center;
}

.vkjp-biotype-badge {
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 8px;
}

#vkjp-biotype-label {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 20px;
}

.vkjp-biotype-scores {
    max-width: 360px;
    margin: 0 auto 24px;
    text-align: left;
}

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

.vkjp-biotype-score-letter {
    font-size: 13px;
    font-weight: 700;
    color: #8b949e;
    width: 16px;
    text-align: center;
    flex-shrink: 0;
}

.vkjp-biotype-score-track {
    flex: 1;
    height: 8px;
    background: rgba(255,255,255,0.08);
    border-radius: 4px;
    overflow: hidden;
}

.vkjp-biotype-score-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.vkjp-biotype-score-value {
    font-size: 13px;
    font-weight: 600;
    color: #e6edf3;
    width: 20px;
    text-align: right;
    flex-shrink: 0;
}

.vkjp-biotype-description {
    font-size: 15px;
    line-height: 1.6;
    color: #8b949e;
    max-width: 540px;
    margin: 0 auto;
    text-align: left;
}

.vkjp-biotype-description p {
    margin: 0 0 12px;
}

.vkjp-biotype-description strong {
    color: #e6edf3;
}

.vkjp-biotype-description ul {
    margin: 0 0 12px;
    padding-left: 20px;
}

.vkjp-biotype-description li {
    margin-bottom: 4px;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .vkjp-title {
        font-size: 24px;
    }

    .vkjp-question-label {
        font-size: 21px;
    }

    .vkjp-input {
        font-size: 18px;
    }

    .vkjp-keyboard-hints {
        display: none;
    }

    .vkjp-nav {
        bottom: 20px;
        right: 20px;
    }

    .vkjp-btn-hint {
        display: none;
    }

    .vkjp-slide {
        padding: 16px;
    }

    .vkjp-option {
        padding: 14px 16px;
    }
}

@media (max-width: 480px) {
    .vkjp-title {
        font-size: 20px;
    }

    .vkjp-question-label {
        font-size: 18px;
    }

    .vkjp-subtitle {
        font-size: 15px;
    }

    .vkjp-btn {
        padding: 12px 24px;
        font-size: 15px;
        width: 100%;
        justify-content: center;
    }
}
