:root {
    --grad-start: #6a11cb;
    --grad-end: #2575fc;
    --bg-main: #ffffff;
    --bg-secondary: #f4f7fc;
    --text-primary: #1e293b;
    --text-muted: #475569;
    --border-color: #e2e8f0;
    --card-shadow: 0 14px 40px rgba(100, 116, 139, 0.18);
    --font-serif: 'Lora', serif;
    --font-sans: 'Inter', sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: var(--font-sans);
    background: var(--bg-main);
    min-height: 100vh;
    color: var(--text-primary);
    -webkit-font-smoothing: antialiased;
    line-height: 1.7;
    font-size: 17px;
}

[v-cloak] {
    display: none;
}

.loader {
    color: var(--text-primary);
    text-align: center;
    padding: 2rem;
}

.signup-shell {
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    background: var(--bg-main);
}

.app-header {
    padding: 1.25rem 5vw;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--text-primary);
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 10;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-family: var(--font-sans);
    font-size: 1.2rem;
    font-weight: 600;
    background: linear-gradient(90deg, var(--grad-start), var(--grad-end));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo img {
    width: 70px;
    height: 70px;
    object-fit: contain;
}

.step-indicator {
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.step-stage {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4rem 0 5rem;
}

.step-screen {
    width: 90%;
    max-width: 1100px;
    margin: 0 auto;
}

.step-stage.plan-view {
    display: block;
    padding: 2rem 0 3rem;
}

.step-stage.plan-view .step-screen {
    margin-bottom: 1.5rem;
}

.question-card {
    background: var(--bg-main);
    border-radius: 24px;
    padding: clamp(1.75rem, 4vw, 3rem);
    border: 1px solid var(--border-color);
    box-shadow: var(--card-shadow);
    width: 100%;
    min-height: clamp(340px, 45vh, 560px);
    display: flex;
    flex-direction: column;
    gap: clamp(1.25rem, 2vw, 2rem);
}

.question-eyebrow {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--grad-end);
    font-weight: 600;
}

.question-card h1 {
    margin: 0;
    font-family: var(--font-sans);
    font-size: clamp(1.8rem, 4vw, 2.4rem);
    font-weight: 600;
    color: var(--text-primary);
}

.question-card p.lead {
    margin: 0;
    font-size: 1.05rem;
    color: var(--text-muted);
}

.action-panel,
.manual-panel,
.selection-panel {
    background: #f8fafc;
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.signin-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    border: none;
    border-radius: 999px;
    padding: 0.85rem 1.75rem;
    font-size: 1rem;
    font-weight: 600;
    background: linear-gradient(135deg, var(--grad-start), var(--grad-end));
    color: #fff;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(37, 117, 252, 0.3);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.signin-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    box-shadow: none;
}

.signin-button:not(:disabled):hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 45px rgba(76, 139, 245, 0.45);
}

.signin-button.secondary {
    background: #fff;
    color: var(--grad-end);
    box-shadow: none;
    border: 2px solid var(--grad-end);
}

.signin-button.secondary:hover {
    box-shadow: 0 8px 18px rgba(37, 117, 252, 0.2);
}

.status-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.9rem;
    padding: 0.4rem 0.85rem;
    border-radius: 999px;
    background: rgba(37, 117, 252, 0.12);
    color: var(--grad-end);
}

.status-chip.error {
    background: rgba(255, 99, 132, 0.15);
    color: #b42318;
}

.manual-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1rem;
}

label {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-primary);
}

input,
select,
textarea {
    width: 100%;
    padding: 0.85rem 0.9rem;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    background: #fff;
    font-family: inherit;
    font-size: 1rem;
    transition: border 0.2s ease, box-shadow 0.2s ease;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--grad-end);
    box-shadow: 0 0 0 3px rgba(37, 117, 252, 0.2);
}

.selection-grid {
    display: grid;
    gap: 1.25rem;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.option-card {
    border-radius: 16px;
    padding: 1.5rem;
    border: 2px solid transparent;
    background: #fff;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.12);
    cursor: pointer;
    transition: border 0.2s ease, transform 0.2s ease;
}

.option-card:hover {
    transform: translateY(-2px);
}

.option-card.selected {
    border-color: var(--grad-end);
    box-shadow: 0 14px 32px rgba(37, 117, 252, 0.25);
}

.option-card h3 {
    margin: 0 0 0.4rem 0;
}

.option-card p {
    margin: 0;
    color: var(--text-muted);
}

.toggle-group {
    display: flex;
    gap: 1rem;
}

.toggle-button {
    flex: 1;
    padding: 1rem 1.2rem;
    border-radius: 18px;
    border: 2px solid var(--border-color);
    background: linear-gradient(135deg, rgba(37, 117, 252, 0.04), rgba(106, 17, 203, 0.04));
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: border 0.2s ease, background 0.2s ease;
}

.toggle-button.selected {
    border-color: var(--grad-end);
    background: linear-gradient(135deg, var(--grad-start), var(--grad-end));
    color: #fff;
    box-shadow: 0 8px 18px rgba(37, 117, 252, 0.28);
}

.helper-copy {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.5;
}

.link-button {
    background: none;
    border: none;
    color: var(--grad-end);
    font-weight: 600;
    cursor: pointer;
    text-decoration: underline;
}

.nav-button {
    position: fixed;
    bottom: 2rem;
    transform: none;
    min-width: 140px;
    border-radius: 999px;
    padding: 0.85rem 1.75rem;
    font-size: 1rem;
    font-weight: 600;
    border: 2px solid transparent;
    cursor: pointer;
    transition: opacity 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.15);
    z-index: 20;
}

.nav-button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    box-shadow: none;
}

.nav-button:hover:not(:disabled) {
    transform: translateY(-2px);
}

.nav-button.primary {
    background: linear-gradient(135deg, var(--grad-start), var(--grad-end));
    color: #fff;
}

.nav-button.secondary {
    background: #fff;
    color: var(--grad-end);
    border: 2px solid var(--grad-end);
}

.nav-prev {
    left: 2rem;
}

.nav-next {
    right: 2rem;
}

.placeholder-panel {
    background: #f8fafc;
    border-radius: 16px;
    padding: 2rem;
    text-align: center;
}

.placeholder-panel h2 {
    margin: 0 0 0.5rem 0;
    font-family: var(--font-sans);
}

.placeholder-panel p {
    margin: 0;
    color: var(--text-muted);
}

.screenshot-tiles {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.screenshot-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: #fff;
    padding: 0.75rem;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
}

.screenshot-tile:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.16);
    border-color: rgba(37, 117, 252, 0.3);
}

.screenshot-tile img {
    width: 100%;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    margin-bottom: 0.5rem;
    max-height: 180px;
    object-fit: cover;
}

.screenshot-tile span {
    font-weight: 600;
    color: var(--text-primary);
    text-align: center;
}

.group-links-list {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    justify-items: center;
}

.group-links-list a {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    gap: 0.4rem;
    padding: 0.25rem 0.7rem;
    border-radius: 16px;
    color: #fff;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.12);
}

.group-links-list a.group-target { background-color: #f8b229; }
.group-links-list a.group-enforced { background-color: #107c10; }
.group-links-list a.group-issue { background-color: #d83b01; }
.group-links-list a.group-help { background-color: #605e5c; }
.group-links-list a:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.18);
}

.screenshot-modal {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    z-index: 200;
}

.screenshot-modal-content {
    background: #fff;
    border-radius: 12px;
    padding: 1rem 1.25rem 1.5rem;
    max-width: min(90vw, 960px);
    width: 100%;
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.25);
    position: relative;
}

.screenshot-modal-image {
    width: 100%;
    height: auto;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    max-height: 75vh;
    object-fit: contain;
}

.example-modal .screenshot-modal-content {
    width: auto;
    max-width: min(90vw, 540px);
    min-width: min(90vw, 340px);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.example-modal .screenshot-modal-image {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

.question-card pre.helper-copy {
    font-family: ui-monospace, SFMono-Regular, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 0.9rem;
}

.modal-close {
    position: absolute;
    top: 0.6rem;
    right: 0.6rem;
    border: none;
    background: rgba(15, 23, 42, 0.05);
    color: var(--text-primary);
    font-size: 1.1rem;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.modal-close:hover {
    background: rgba(37, 117, 252, 0.12);
}

.fade-slide-enter-active,
.fade-slide-leave-active {
    transition: opacity 0.35s ease, transform 0.35s ease;
}

.fade-slide-enter-from,
.fade-slide-leave-to {
    opacity: 0;
    transform: translateY(30px);
}

@media (max-width: 768px) {
    .app-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .question-card {
        border-radius: 24px;
    }

    .step-stage {
        padding: 1.5rem 1rem 5.5rem;
    }

    .nav-button {
        position: fixed;
        top: auto;
        bottom: 1.5rem;
        transform: none;
        width: calc(50% - 1.5rem);
        box-shadow: 0 10px 20px rgba(15, 23, 42, 0.15);
    }

    .nav-button:hover:not(:disabled) {
        transform: translateY(-2px);
    }

    .nav-prev {
        left: 1rem;
    }

    .nav-next {
        right: 1rem;
    }
}
