/* diagnostic.css — Rocket Diagnostic Engine Addon */

/* ═══════════════════════════════════════════════
   LAYOUT & SCREENS
   ═══════════════════════════════════════════════ */

.diag-app {
    min-height: 100vh;
    padding-top: 6rem;
    position: relative;
    z-index: 2;
}

.diag-screen {
    display: none;
    animation: diagFadeIn 0.6s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

.diag-screen.active {
    display: block;
}

@keyframes diagFadeIn {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ═══════════════════════════════════════════════
   LANDING SCREEN
   ═══════════════════════════════════════════════ */

.diag-landing {
    min-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem;
}

.diag-landing-content {
    max-width: 720px;
}

.diag-landing h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 1.5rem;
    line-height: 1.05;
}

.diag-landing .diag-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.7;
}

.diag-landing .diag-value-props {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin: 2.5rem 0 3rem;
}

.diag-value-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.2rem;
    border-radius: 100px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.diag-value-chip .chip-icon {
    font-size: 1.1rem;
}

.diag-time-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 1.5rem;
}

/* ═══════════════════════════════════════════════
   PROGRESS BAR
   ═══════════════════════════════════════════════ */

.diag-progress-wrapper {
    position: fixed;
    top: 72px;
    left: 0;
    width: 100%;
    z-index: 50;
    padding: 0;
    background: rgba(3, 3, 3, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.diag-progress-inner {
    max-width: 700px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.diag-progress-label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.diag-progress-track {
    flex: 1;
    height: 4px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 100px;
    overflow: hidden;
}

.diag-progress-fill {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: 100px;
    transition: width 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    box-shadow: 0 0 12px rgba(255, 207, 58, 0.4);
}

.diag-progress-step {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--accent-yellow);
    white-space: nowrap;
}

/* ═══════════════════════════════════════════════
   FORM BLOCKS
   ═══════════════════════════════════════════════ */

.diag-form-screen {
    max-width: 700px;
    margin: 0 auto;
    padding: 6rem 2rem 4rem;
}

.diag-block-header {
    margin-bottom: 2.5rem;
}

.diag-block-badge {
    display: inline-block;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    background: rgba(255, 207, 58, 0.08);
    border: 1px solid rgba(255, 207, 58, 0.15);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent-yellow);
    margin-bottom: 1rem;
}

.diag-block-header h2 {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    margin-bottom: 0.75rem;
}

.diag-block-header p {
    color: var(--text-secondary);
    font-size: 1.05rem;
}

/* ═══════════════════════════════════════════════
   FORM FIELDS
   ═══════════════════════════════════════════════ */

.diag-field {
    margin-bottom: 2rem;
}

.diag-field label {
    display: block;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.6rem;
}

.diag-field .field-hint {
    display: block;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
    font-weight: 400;
}

.diag-input {
    width: 100%;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 1.1rem 1.4rem;
    color: var(--text-primary);
    font-size: 1rem;
    font-family: var(--font-main);
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.4);
}

.diag-input::placeholder {
    color: rgba(255, 255, 255, 0.15);
}

.diag-input:focus {
    outline: none;
    border-color: rgba(255, 207, 58, 0.4);
    background: rgba(0, 0, 0, 0.55);
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.4), 0 0 16px rgba(255, 207, 58, 0.08);
}

.diag-select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23a1a1aa' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1.2rem center;
    padding-right: 3rem;
    cursor: pointer;
}

.diag-select option {
    background: #0a0a0a;
    color: var(--text-primary);
}

/* Choice Grid (radio/buttons) */
.diag-choice-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.diag-choice-grid.single-col {
    grid-template-columns: 1fr;
}

.diag-choice {
    position: relative;
    cursor: pointer;
}

.diag-choice input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.diag-choice .choice-label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(0, 0, 0, 0.3);
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.25s ease;
    cursor: pointer;
}

.diag-choice .choice-label:hover {
    border-color: rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-primary);
}

.diag-choice input[type="radio"]:checked + .choice-label {
    border-color: rgba(255, 207, 58, 0.5);
    background: rgba(255, 207, 58, 0.06);
    color: var(--text-primary);
    box-shadow: 0 0 20px rgba(255, 207, 58, 0.06);
}

.diag-choice .choice-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
}

/* Slider Field */
.diag-slider-wrapper {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.diag-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    border-radius: 100px;
    background: rgba(255, 255, 255, 0.06);
    outline: none;
    cursor: pointer;
}

.diag-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--gradient-primary);
    cursor: pointer;
    box-shadow: 0 0 10px rgba(255, 207, 58, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.2);
    transition: transform 0.2s ease;
}

.diag-slider::-webkit-slider-thumb:hover {
    transform: scale(1.15);
}

.diag-slider::-moz-range-thumb {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--gradient-primary);
    cursor: pointer;
    box-shadow: 0 0 10px rgba(255, 207, 58, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.diag-slider-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.diag-slider-value {
    text-align: center;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--accent-yellow);
    margin-top: 0.25rem;
}

/* ═══════════════════════════════════════════════
   FORM NAVIGATION
   ═══════════════════════════════════════════════ */

.diag-nav {
    display: flex;
    gap: 1rem;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.diag-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 1rem;
    font-family: var(--font-main);
    cursor: pointer;
    border: none;
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    position: relative;
    overflow: hidden;
}

.diag-btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: 0 6px 20px rgba(254, 74, 86, 0.25);
    flex: 1;
}

.diag-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(254, 74, 86, 0.4);
}

.diag-btn-primary:active {
    transform: translateY(0);
}

.diag-btn-secondary {
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.diag-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    border-color: rgba(255, 255, 255, 0.2);
}

.diag-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none !important;
}

/* ═══════════════════════════════════════════════
   RESULTS — SHARED
   ═══════════════════════════════════════════════ */

.diag-results {
    max-width: 800px;
    margin: 0 auto;
    padding: 4rem 2rem 6rem;
}

.diag-results-header {
    text-align: center;
    margin-bottom: 3rem;
}

.diag-results-header h2 {
    font-size: clamp(2rem, 4vw, 2.75rem);
    margin-bottom: 0.75rem;
}

.diag-results-header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Score Gauge */
.diag-score-gauge {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 3rem 0;
}

.diag-score-ring {
    position: relative;
    width: 200px;
    height: 200px;
}

.diag-score-ring svg {
    transform: rotate(-90deg);
    width: 200px;
    height: 200px;
}

.diag-score-ring .ring-bg {
    fill: none;
    stroke: rgba(255, 255, 255, 0.04);
    stroke-width: 8;
}

.diag-score-ring .ring-fill {
    fill: none;
    stroke: url(#scoreGradient);
    stroke-width: 8;
    stroke-linecap: round;
    stroke-dasharray: 565.48;
    stroke-dashoffset: 565.48;
    transition: stroke-dashoffset 1.5s cubic-bezier(0.25, 1, 0.5, 1);
}

.diag-score-number {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.diag-score-number .score-value {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.diag-score-number .score-max {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.diag-score-band {
    margin-top: 1rem;
    padding: 0.5rem 1.5rem;
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.band-critico {
    background: rgba(254, 74, 86, 0.15);
    color: #FE4A56;
    border: 1px solid rgba(254, 74, 86, 0.3);
}

.band-inestable {
    background: rgba(255, 165, 0, 0.15);
    color: #FFA500;
    border: 1px solid rgba(255, 165, 0, 0.3);
}

.band-funcional {
    background: rgba(255, 207, 58, 0.15);
    color: #FFCF3A;
    border: 1px solid rgba(255, 207, 58, 0.3);
}

.band-solido {
    background: rgba(74, 222, 128, 0.15);
    color: #4ADE80;
    border: 1px solid rgba(74, 222, 128, 0.3);
}

/* Bottleneck Card */
.diag-bottleneck {
    background: var(--bg-card);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(254, 74, 86, 0.2);
    border-radius: 16px;
    padding: 2rem 2.5rem;
    margin: 2.5rem 0;
    position: relative;
    overflow: hidden;
}

.diag-bottleneck::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 4px;
    height: 100%;
    background: var(--accent-red);
}

.diag-bottleneck-label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent-red);
    margin-bottom: 0.5rem;
}

.diag-bottleneck h3 {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}

.diag-bottleneck p {
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.7;
}

/* Reading Card */
.diag-reading {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 2.5rem;
    margin: 2rem 0;
}

.diag-reading h3 {
    font-size: 1.25rem;
    margin-bottom: 1.25rem;
    color: var(--text-primary);
}

.diag-reading p {
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.8;
    margin-bottom: 1rem;
}

/* Recommendation Card */
.diag-recommendation {
    background: linear-gradient(135deg, rgba(255, 207, 58, 0.04) 0%, rgba(254, 74, 86, 0.04) 100%);
    border: 1px solid rgba(255, 207, 58, 0.15);
    border-radius: 16px;
    padding: 2.5rem;
    margin: 2rem 0;
}

.diag-recommendation-label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent-yellow);
    margin-bottom: 0.75rem;
}

.diag-recommendation h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.diag-recommendation p {
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.7;
}

/* CTA Unlock Card */
.diag-unlock-cta {
    text-align: center;
    padding: 3.5rem 2rem;
    margin: 3rem 0;
    background: linear-gradient(135deg, rgba(255, 207, 58, 0.06) 0%, rgba(254, 74, 86, 0.06) 100%);
    border: 1px solid rgba(255, 207, 58, 0.25);
    border-radius: 20px;
    position: relative;
    overflow: hidden;
}

.diag-unlock-cta::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: var(--gradient-glow);
    opacity: 0.03;
    pointer-events: none;
}

.diag-unlock-cta h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.diag-unlock-cta p {
    color: var(--text-secondary);
    font-size: 1.05rem;
    max-width: 500px;
    margin: 0 auto 2rem;
    line-height: 1.6;
}

.diag-unlock-features {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 2.5rem;
}

.diag-unlock-feature {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

/* ═══════════════════════════════════════════════
   PRIVATE RESULTS — DIMENSION SCORES
   ═══════════════════════════════════════════════ */

.diag-dimensions {
    display: grid;
    gap: 1.25rem;
    margin: 2.5rem 0;
}

.diag-dimension {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.25rem 1.5rem;
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    transition: border-color 0.3s ease;
}

.diag-dimension:hover {
    border-color: rgba(255, 255, 255, 0.1);
}

.diag-dimension-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
    width: 40px;
    text-align: center;
}

.diag-dimension-info {
    flex: 1;
    min-width: 0;
}

.diag-dimension-name {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
}

.diag-dimension-bar {
    height: 6px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 100px;
    overflow: hidden;
}

.diag-dimension-bar-fill {
    height: 100%;
    border-radius: 100px;
    transition: width 1s cubic-bezier(0.25, 1, 0.5, 1);
    background: var(--gradient-primary);
}

.diag-dimension-score {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--accent-yellow);
    white-space: nowrap;
    min-width: 40px;
    text-align: right;
}

/* 30-Day Plan */
.diag-plan {
    margin: 3rem 0;
}

.diag-plan h3 {
    font-size: 1.5rem;
    margin-bottom: 2rem;
}

.diag-plan-week {
    position: relative;
    padding-left: 2rem;
    padding-bottom: 2.5rem;
    border-left: 2px solid rgba(255, 255, 255, 0.06);
}

.diag-plan-week:last-child {
    border-left-color: transparent;
    padding-bottom: 0;
}

.diag-plan-week::before {
    content: '';
    position: absolute;
    left: -6px;
    top: 4px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--gradient-primary);
    box-shadow: 0 0 10px rgba(255, 207, 58, 0.4);
}

.diag-plan-week h4 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--accent-yellow);
    margin-bottom: 0.5rem;
}

.diag-plan-week p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
}

/* Rocket CTA */
.diag-rocket-cta {
    text-align: center;
    padding: 4rem 2rem;
    margin: 3rem 0;
    background: linear-gradient(135deg, rgba(255, 207, 58, 0.05) 0%, rgba(254, 74, 86, 0.05) 100%);
    border: 1px solid rgba(255, 207, 58, 0.3);
    border-radius: 24px;
    position: relative;
    overflow: hidden;
}

.diag-rocket-cta h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.diag-rocket-cta p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 550px;
    margin: 0 auto 2.5rem;
}

/* ═══════════════════════════════════════════════
   AUTH MODAL
   ═══════════════════════════════════════════════ */

.diag-auth-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 200;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.diag-auth-overlay.active {
    display: flex;
}

.diag-auth-modal {
    background: #0a0a0a;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 3rem;
    max-width: 440px;
    width: 100%;
    position: relative;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
    animation: diagFadeIn 0.4s ease forwards;
}

.diag-auth-close {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.25rem;
    line-height: 1;
    transition: color 0.2s;
}

.diag-auth-close:hover {
    color: var(--text-primary);
}

.diag-auth-modal h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.diag-auth-modal .auth-desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 2rem;
}

.diag-auth-modal .diag-field {
    margin-bottom: 1.25rem;
}

.diag-auth-error {
    color: var(--accent-red);
    font-size: 0.85rem;
    margin-bottom: 1rem;
    display: none;
}

.diag-auth-toggle {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.diag-auth-toggle a {
    color: var(--accent-yellow);
    font-weight: 600;
    cursor: pointer;
}

.diag-auth-toggle a:hover {
    text-decoration: underline;
}

/* Google Sign-In Button */
.diag-btn-google {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.9rem 1.5rem;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-primary);
    font-size: 0.95rem;
    font-weight: 600;
    font-family: var(--font-main);
    cursor: pointer;
    transition: all 0.25s ease;
}

.diag-btn-google:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.25);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

.diag-btn-google svg {
    flex-shrink: 0;
}

/* Auth Divider */
.diag-auth-divider {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 1.25rem 0;
}

.diag-auth-divider::before,
.diag-auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255, 255, 255, 0.08);
}

.diag-auth-divider span {
    font-size: 0.8rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

/* ═══════════════════════════════════════════════
   USER BAR (AUTHENTICATED)
   ═══════════════════════════════════════════════ */

.diag-user-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    margin-bottom: 2rem;
    background: rgba(74, 222, 128, 0.04);
    border: 1px solid rgba(74, 222, 128, 0.15);
    border-radius: 12px;
}

.diag-user-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 600;
    font-size: 0.95rem;
}

.diag-user-avatar {
    font-size: 1.25rem;
}

.diag-logout-btn {
    color: var(--text-secondary);
    font-size: 0.85rem;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s;
}

.diag-logout-btn:hover {
    color: var(--accent-red);
}

/* Unlock Section (non-authenticated) */
.diag-unlock {
    text-align: center;
    padding: 3.5rem 2rem;
    margin: 3rem 0;
    background: linear-gradient(135deg, rgba(255, 207, 58, 0.06) 0%, rgba(254, 74, 86, 0.06) 100%);
    border: 1px solid rgba(255, 207, 58, 0.25);
    border-radius: 20px;
    position: relative;
    overflow: hidden;
}

.diag-unlock h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.diag-unlock p {
    color: var(--text-secondary);
    font-size: 1.05rem;
    max-width: 500px;
    margin: 0 auto 2rem;
    line-height: 1.6;
}

.diag-unlock-features {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 2.5rem;
}

.diag-unlock-features span {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

/* ═══════════════════════════════════════════════
   DIAGNOSTIC HISTORY
   ═══════════════════════════════════════════════ */

.diag-history {
    margin: 3rem 0 0;
}

.diag-history h3 {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
}

.diag-history-entry {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1rem 1.5rem;
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    margin-bottom: 0.75rem;
    transition: border-color 0.2s;
}

.diag-history-entry:hover {
    border-color: rgba(255, 255, 255, 0.1);
}

.diag-history-date {
    font-size: 0.85rem;
    color: var(--text-secondary);
    min-width: 100px;
}

.diag-history-score {
    font-size: 0.95rem;
    flex: 1;
}

.diag-history-bn {
    font-size: 0.85rem;
    color: var(--accent-yellow);
    text-align: right;
}

/* ═══════════════════════════════════════════════
   EXTENDED FORM (PRIVATE)
   ═══════════════════════════════════════════════ */

.diag-extended-intro {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 3rem;
    padding-top: 2rem;
}

.diag-extended-intro h2 {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    margin-bottom: 1rem;
}

.diag-extended-intro p {
    color: var(--text-secondary);
    font-size: 1.05rem;
}

/* ═══════════════════════════════════════════════
   LOADING STATE
   ═══════════════════════════════════════════════ */

.diag-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 50vh;
    gap: 1.5rem;
    text-align: center;
}

.diag-loading-spinner {
    width: 48px;
    height: 48px;
    border: 3px solid rgba(255, 255, 255, 0.06);
    border-top: 3px solid var(--accent-yellow);
    border-radius: 50%;
    animation: diagSpin 0.8s linear infinite;
}

@keyframes diagSpin {
    to { transform: rotate(360deg); }
}

.diag-loading p {
    color: var(--text-secondary);
    font-size: 1.05rem;
}

/* ═══════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════ */

@media (max-width: 600px) {
    .diag-form-screen {
        padding: 5rem 1.25rem 3rem;
    }

    .diag-choice-grid {
        grid-template-columns: 1fr;
    }

    .diag-results {
        padding: 3rem 1.25rem 4rem;
    }

    .diag-score-ring {
        width: 160px;
        height: 160px;
    }

    .diag-score-ring svg {
        width: 160px;
        height: 160px;
    }

    .diag-score-number .score-value {
        font-size: 2.75rem;
    }

    .diag-bottleneck,
    .diag-reading,
    .diag-recommendation {
        padding: 1.75rem;
    }

    .diag-dimension {
        flex-wrap: wrap;
        gap: 0.75rem;
    }

    .diag-unlock-cta,
    .diag-unlock,
    .diag-rocket-cta {
        padding: 2.5rem 1.5rem;
    }

    .diag-user-bar {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }

    .diag-history-entry {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }

    .diag-history-date,
    .diag-history-bn {
        text-align: center;
    }

    .diag-auth-modal {
        padding: 2rem 1.5rem;
    }

    .diag-nav {
        flex-direction: column;
    }

    .diag-landing h1 {
        font-size: clamp(2rem, 5vw, 3rem);
    }

    .diag-progress-inner {
        padding: 0.75rem 1rem;
    }
}

/* FODA (SWOT) Styles */
.diag-foda {
    margin: 3rem 0;
    padding: 2.5rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.diag-foda h3 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 1.75rem;
    color: var(--text-primary);
}

.foda-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.foda-box {
    padding: 1.5rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.foda-box-label {
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.foda-f .foda-box-label { color: #4ADE80; } /* Strengths */
.foda-o .foda-box-label { color: #60A5FA; } /* Opportunities */
.foda-d .foda-box-label { color: #FBBF24; } /* Weaknesses */
.foda-a .foda-box-label { color: #F87171; } /* Threats */

.foda-box ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.foda-box li {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 0.6rem;
    padding-left: 1.25rem;
    position: relative;
}

.foda-box li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--text-primary);
    opacity: 0.4;
}

/* PESTLE Styles */
.diag-pestle {
    margin: 3rem 0;
    padding: 2.5rem;
    background: rgba(10, 10, 10, 0.4);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.diag-pestle h3 {
    text-align: center;
    margin-bottom: 2.5rem;
    font-size: 1.75rem;
}

.pestle-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.pestle-item {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.pestle-item strong {
    color: var(--accent-yellow);
    font-size: 1.25rem;
    display: block;
    margin-bottom: 0.5rem;
}

@media (max-width: 768px) {
    .foda-grid { grid-template-columns: 1fr; }
    .pestle-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
    .pestle-grid { grid-template-columns: 1fr; }
}

/* Chatbot Styles */
.chatbot-widget {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 999;
}

.chatbot-toggle {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--gradient-primary);
    border: none;
    box-shadow: 0 10px 30px rgba(254, 74, 86, 0.3);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.chatbot-toggle:hover {
    transform: scale(1.1);
}

.chatbot-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 380px;
    height: 500px;
    background: var(--bg-card);
    backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
    display: none;
    flex-direction: column;
    overflow: hidden;
    animation: chatOpen 0.4s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

@keyframes chatOpen {
    from { opacity: 0; transform: translateY(20px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.chatbot-header {
    padding: 1.25rem;
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.chatbot-title {
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-primary);
}

.chatbot-messages {
    flex: 1;
    overflow-y: auto;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    scrollbar-width: thin;
}

.chat-msg {
    max-width: 85%;
    padding: 0.8rem 1.2rem;
    border-radius: 16px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.chat-msg.bot {
    align-self: flex-start;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    border-bottom-left-radius: 4px;
}

.chat-msg.user {
    align-self: flex-end;
    background: var(--gradient-primary);
    color: white;
    border-bottom-right-radius: 4px;
}

.chatbot-input-area {
    padding: 1.25rem;
    background: rgba(255, 255, 255, 0.03);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    gap: 0.75rem;
}

.chatbot-input {
    flex: 1;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 100px;
    padding: 0.6rem 1.2rem;
    color: white;
    font-family: inherit;
}

.chatbot-send {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--accent-yellow);
    border: none;
    color: black;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}
