:root {
    --violet: #6c4cff;
    --violet-dark: #5135d8;
    --violet-soft: #eeeaff;
    --blue: #4d83ff;
    --blue-dark: #3569dc;
    --blue-soft: #edf4ff;
    --coral: #ff7568;
    --coral-soft: #fff0ed;
    --ink: #171827;
    --ink-soft: #4e5063;
    --muted: #85879a;
    --light-text: #a0a1b1;
    --white: #ffffff;
    --background: #f7f7ff;
    --border: rgba(75, 73, 130, 0.10);
    --border-blue: rgba(77, 131, 255, 0.20);
    --shadow-small: 0 8px 24px rgba(54, 47, 115, 0.07);
    --shadow-card: 0 22px 60px rgba(54, 47, 115, 0.11);
    --shadow-button: 0 13px 30px rgba(108, 76, 255, 0.28);
    --radius-sm: 12px;
    --radius-md: 18px;
    --radius-lg: 28px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    font-family: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--ink);
    background:
        radial-gradient(circle at 8% 8%, rgba(108, 76, 255, 0.13), transparent 28%),
        radial-gradient(circle at 92% 12%, rgba(77, 131, 255, 0.13), transparent 28%),
        radial-gradient(circle at 80% 88%, rgba(255, 117, 104, 0.08), transparent 25%),
        linear-gradient(135deg, #faf9ff 0%, #f3f6ff 52%, #faf8ff 100%);
    overflow-x: hidden;
}

.background-orb {
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: -1;
    filter: blur(3px);
}

.orb-one {
    width: 300px;
    height: 300px;
    top: -150px;
    right: -90px;
    background: rgba(108, 76, 255, 0.08);
}

.orb-two {
    width: 250px;
    height: 250px;
    bottom: 5%;
    left: -130px;
    background: rgba(77, 131, 255, 0.07);
}

.orb-three {
    width: 180px;
    height: 180px;
    top: 45%;
    right: 4%;
    background: rgba(255, 117, 104, 0.05);
}

.app-container {
    min-height: 100vh;
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 42px 24px 80px;
}

.app-inner {
    width: 100%;
    max-width: 1050px;
    position: relative;
}

#bar-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: rgba(108, 76, 255, 0.08);
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

#bar-container.visible {
    opacity: 1;
}

#step-progress-fill {
    width: 0%;
    height: 100%;
    border-radius: 0 999px 999px 0;
    background: linear-gradient(90deg, var(--violet), var(--blue));
    box-shadow: 0 0 16px rgba(108, 76, 255, 0.35);
    transition: width 0.5s cubic-bezier(.4, 0, .2, 1);
}

.screen {
    display: none;
    width: 100%;
    animation: screenAppear 0.42s cubic-bezier(.2, .8, .2, 1);
}

.screen.active {
    display: block;
}

@keyframes screenAppear {
    from {
        opacity: 0;
        transform: translateY(14px) scale(0.985);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

h1,
h2,
h3 {
    font-family: "Space Grotesk", "DM Sans", sans-serif;
    color: var(--ink);
    letter-spacing: -0.035em;
}

h1 {
    font-size: clamp(2.7rem, 6vw, 4.8rem);
    line-height: 0.98;
    font-weight: 700;
}

h2 {
    font-size: clamp(2rem, 4vw, 3.25rem);
    line-height: 1.04;
    font-weight: 700;
}

h3 {
    font-size: 1.05rem;
    line-height: 1.2;
    font-weight: 700;
}

p {
    line-height: 1.6;
}

.gradient-text {
    background: linear-gradient(100deg, var(--violet), var(--blue));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 13px;
    border: 1px solid rgba(108, 76, 255, 0.12);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.78);
    box-shadow: 0 6px 18px rgba(54, 47, 115, 0.05);
    color: var(--violet-dark);
    font-family: "DM Sans", sans-serif;
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.025em;
}

#screen-welcome {
    min-height: calc(100vh - 110px);
    display: none;
    align-items: center;
    justify-content: center;
}

#screen-welcome.active {
    display: flex;
}

.welcome-content {
    max-width: 820px;
    margin: auto;
    text-align: center;
}

.welcome-content .badge {
    margin-bottom: 28px;
}

.welcome-content h1 {
    margin-bottom: 24px;
}

.welcome-content p {
    max-width: 620px;
    margin: 0 auto 34px;
    color: var(--ink-soft);
    font-size: 1.06rem;
}

.hero-icon {
    width: 92px;
    height: 92px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    border: 1px solid rgba(108, 76, 255, 0.12);
    border-radius: 28px;
    background: linear-gradient(145deg, #ffffff, #eeeaff);
    color: var(--violet);
    font-size: 2.2rem;
    box-shadow: 0 20px 45px rgba(80, 60, 180, 0.13);
    transform: rotate(-3deg);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hero-icon:hover {
    transform: rotate(3deg) translateY(-4px);
    box-shadow: 0 25px 55px rgba(80, 60, 180, 0.18);
}

button {
    border: none;
    font-family: "DM Sans", sans-serif;
    cursor: pointer;
}

.primary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 11px;
    min-height: 58px;
    padding: 0 25px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 17px;
    background: linear-gradient(135deg, var(--violet), #8064ff);
    color: white;
    font-size: 0.98rem;
    font-weight: 700;
    box-shadow: var(--shadow-button);
    transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.primary-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 17px 36px rgba(108, 76, 255, 0.34);
    filter: brightness(1.04);
}

.primary-button:active {
    transform: translateY(0) scale(0.98);
}

.primary-button i {
    transition: transform 0.25s ease;
}

.primary-button:hover i {
    transform: translateX(4px);
}

button:disabled {
    opacity: 0.65;
    cursor: not-allowed;
    transform: none !important;
}

#screen-input {
    max-width: 760px;
    margin: 50px auto 0;
}

.screen-header {
    margin-bottom: 28px;
}

.screen-header .badge {
    margin-bottom: 18px;
}

#screen-input h2 {
    margin-bottom: 13px;
}

.screen-subtitle {
    max-width: 620px;
    color: var(--ink-soft);
    font-size: 1rem;
}

.input-card {
    padding: 27px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.84);
    box-shadow: var(--shadow-card);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.input-label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 11px;
    color: var(--ink-soft);
    font-size: 0.83rem;
    font-weight: 700;
}

.input-label i {
    color: var(--violet);
}

#task-input {
    width: 100%;
    min-height: 66px;
    padding: 0 19px;
    border: 2px solid rgba(108, 76, 255, 0.13);
    border-radius: 17px;
    outline: none;
    background: #fbfaff;
    color: var(--ink);
    font-family: "DM Sans", sans-serif;
    font-size: 1rem;
    font-weight: 500;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

#task-input::placeholder {
    color: #85869a;
    font-weight: 400;
}

#task-input:hover {
    border-color: rgba(108, 76, 255, 0.25);
}

#task-input:focus {
    background: white;
    border-color: var(--violet);
    box-shadow: 0 0 0 5px rgba(108, 76, 255, 0.09);
}

.input-actions {
    display: flex;
    gap: 12px;
    margin-top: 14px;
}

#btn-generate {
    flex: 1;
}

#btn-voice {
    width: 58px;
    min-width: 58px;
    border-radius: 17px;
    background: var(--violet-soft);
    color: var(--violet);
    font-size: 1rem;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

#btn-voice:hover {
    transform: translateY(-2px);
    background: #e4deff;
    box-shadow: 0 8px 18px rgba(108, 76, 255, 0.12);
}

#btn-voice.recording {
    background: var(--coral-soft);
    color: var(--coral);
    animation: voicePulse 1.2s infinite;
}

@keyframes voicePulse {
    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(255, 117, 104, 0.18);
    }

    50% {
        box-shadow: 0 0 0 9px rgba(255, 117, 104, 0.03);
    }
}

.input-helper {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-top: 13px;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 500;
}

.input-helper i {
    color: var(--violet);
    font-size: 0.72rem;
}

.input-helper-message {
    min-height: 22px;
    margin-top: 7px;
    color: var(--coral);
    font-size: 0.84rem;
    font-weight: 600;
    opacity: 0;
    transform: translateY(-4px);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.input-helper-message.show {
    opacity: 1;
    transform: translateY(0);
}

.detail-level-section {
    margin-top: 24px;
    padding: 18px;
    border: 1px solid rgba(108, 76, 255, 0.10);
    border-radius: 20px;
    background: linear-gradient(135deg, rgba(246, 243, 255, 0.92), rgba(241, 246, 255, 0.82));
}

.detail-level-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 13px;
    color: var(--ink-soft);
    font-family: "Space Grotesk", sans-serif;
    font-size: 0.82rem;
    font-weight: 700;
}

.detail-level-title i {
    color: var(--violet);
    font-size: 0.85rem;
}

.detail-level-options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.detail-option {
    position: relative;
    min-height: 82px;
    padding: 15px 12px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    text-align: left;
    border: 1.5px solid rgba(108, 76, 255, 0.13);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.78);
    color: var(--ink);
    box-shadow: 0 5px 15px rgba(54, 47, 115, 0.04);
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.detail-option:hover {
    transform: translateY(-2px);
    border-color: rgba(108, 76, 255, 0.32);
    background: #ffffff;
    box-shadow: 0 9px 22px rgba(108, 76, 255, 0.10);
}

.detail-option.active {
    border-color: var(--violet);
    background: linear-gradient(145deg, #f0edff, #ffffff);
    box-shadow: 0 8px 22px rgba(108, 76, 255, 0.13), inset 0 0 0 1px rgba(108, 76, 255, 0.06);
}

.detail-option.active::before {
    content: "";
    position: absolute;
    top: 10px;
    right: 10px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--violet);
    box-shadow: 0 0 0 4px rgba(108, 76, 255, 0.10);
}

.detail-option-name {
    display: block;
    margin-bottom: 4px;
    color: var(--ink);
    font-family: "Space Grotesk", sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
}

.detail-option-description {
    display: block;
    color: var(--muted);
    font-size: 0.72rem;
    line-height: 1.35;
    font-weight: 500;
}

.detail-option.active .detail-option-name {
    color: var(--violet-dark);
}

.detail-option.active .detail-option-description {
    color: #69657f;
}

#screen-list {
    max-width: 800px;
    margin: 50px auto 0;
}

.action-map-card {
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.88);
    box-shadow: var(--shadow-card);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.action-map-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 24px 25px;
    border-bottom: 1px solid rgba(77, 131, 255, 0.10);
    background: linear-gradient(135deg, rgba(238, 234, 255, 0.62), rgba(237, 244, 255, 0.48));
}

.action-map-title {
    display: flex;
    align-items: center;
    gap: 13px;
}

.action-map-icon {
    width: 43px;
    height: 43px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(108, 76, 255, 0.14);
    border-radius: 14px;
    background: white;
    color: var(--violet);
    box-shadow: 0 7px 18px rgba(108, 76, 255, 0.08);
}

.action-map-title h3 {
    margin-bottom: 3px;
    font-size: 0.98rem;
}

.action-map-title p {
    color: var(--muted);
    font-size: 0.76rem;
    line-height: 1.4;
}

.action-map-decoration {
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--light-text);
    font-family: "Space Grotesk", sans-serif;
    font-size: 0.7rem;
    font-weight: 600;
}

.action-map-decoration span {
    width: 27px;
    height: 27px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(77, 131, 255, 0.18);
    border-radius: 9px;
    background: white;
    color: var(--blue);
}

.action-map-decoration i {
    font-size: 0.58rem;
    color: #b1b5c5;
}

.steps-preview-container {
    padding: 12px 15px;
}

.preview-step {
    position: relative;
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) 28px;
    align-items: center;
    gap: 15px;
    padding: 17px 12px;
    border: 1px solid transparent;
    border-radius: 18px;
    background: transparent;
    transition: background 0.22s ease, border-color 0.22s ease, transform 0.22s ease, box-shadow 0.22s ease;
}

.preview-step + .preview-step {
    border-top: 1px solid rgba(75, 73, 130, 0.06);
    border-radius: 0;
}

.preview-step + .preview-step:hover {
    border-radius: 18px;
    border-top-color: transparent;
}

.preview-step:hover {
    transform: translateX(3px);
    border-color: rgba(77, 131, 255, 0.13);
    background: linear-gradient(90deg, rgba(237, 244, 255, 0.65), rgba(238, 234, 255, 0.45));
    box-shadow: 0 7px 20px rgba(77, 131, 255, 0.06);
}

.preview-step-number {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid rgba(77, 131, 255, 0.38);
    border-radius: 13px;
    background: linear-gradient(145deg, #ffffff, #f2f5ff);
    color: var(--blue-dark);
    font-family: "Space Grotesk", sans-serif;
    font-size: 0.82rem;
    font-weight: 700;
    box-shadow: 0 5px 13px rgba(77, 131, 255, 0.08);
}

.preview-step-content {
    min-width: 0;
}

.preview-step-label {
    display: block;
    margin-bottom: 4px;
    color: var(--violet);
    font-family: "Space Grotesk", sans-serif;
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.10em;
    text-transform: uppercase;
}

.preview-step-text {
    color: #303447;
    font-family: "DM Sans", sans-serif;
    font-size: 0.96rem;
    font-weight: 500;
    line-height: 1.5;
    letter-spacing: -0.006em;
}

.preview-step-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 9px;
    color: var(--blue);
    font-family: "DM Sans", sans-serif;
    font-size: 1rem;
    transition: transform 0.2s ease, background 0.2s ease;
}

.preview-step:hover .preview-step-arrow {
    transform: translateX(4px);
    background: rgba(77, 131, 255, 0.08);
}

.action-map-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 18px 25px 22px;
    border-top: 1px solid rgba(75, 73, 130, 0.07);
}

.action-map-footer-hint {
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 500;
}

.action-map-footer-hint i {
    color: var(--coral);
}

#screen-focus {
    max-width: 760px;
    margin: 60px auto 0;
}

.focus-card {
    position: relative;
    padding: 44px 42px;
    border: 1px solid rgba(108, 76, 255, 0.10);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.91);
    box-shadow: var(--shadow-card);
    text-align: center;
}

.focus-step-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-bottom: 17px;
}

.focus-step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 49px;
    height: 49px;
    border: 1.5px solid rgba(77, 131, 255, 0.30);
    border-radius: 15px;
    background: var(--blue-soft);
    color: var(--blue-dark);
    font-family: "Space Grotesk", sans-serif;
    font-size: 1.1rem;
    font-weight: 700;
}

.focus-step-divider {
    color: #b5b6c4;
    font-size: 0.85rem;
}

.focus-total-steps {
    color: var(--muted);
    font-family: "Space Grotesk", sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
}

.focus-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-bottom: 14px;
    color: var(--violet);
    font-family: "Space Grotesk", sans-serif;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.12em;
}

.focus-eyebrow i {
    font-size: 0.65rem;
}

.focus-step-text {
    max-width: 620px;
    margin: 0 auto 30px;
    color: #282b3c;
    font-family: "DM Sans", sans-serif;
    font-size: clamp(1.35rem, 3.5vw, 1.85rem);
    font-weight: 600;
    line-height: 1.35;
    letter-spacing: -0.018em;
}

#focus-helper-banner {
    display: none;
    margin: 0 auto 18px;
    padding: 10px 14px;
    border: 1px solid rgba(255, 117, 104, 0.14);
    border-radius: 12px;
    background: var(--coral-soft);
    color: #d95c50;
    font-size: 0.82rem;
    font-weight: 600;
}

#focus-helper-banner.show {
    display: inline-flex;
    animation: messageIn 0.25s ease;
}

@keyframes messageIn {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.focus-actions {
    display: flex;
    justify-content: center;
    gap: 13px;
}

#btn-success,
#btn-fail {
    width: 58px;
    height: 58px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    font-size: 1rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

#btn-success {
    background: var(--violet);
    color: white;
    box-shadow: 0 11px 26px rgba(108, 76, 255, 0.25);
}

#btn-fail {
    background: #f2f1f7;
    color: var(--ink-soft);
}

#btn-success:hover,
#btn-fail:hover {
    transform: translateY(-3px);
}

#btn-success:hover {
    box-shadow: 0 15px 31px rgba(108, 76, 255, 0.31);
}

.focus-microcopy {
    margin-top: 16px;
    color: var(--light-text);
    font-size: 0.74rem;
    font-weight: 500;
}

.focus-card.shake {
    animation: shake 0.38s ease;
}

@keyframes shake {
    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-7px);
    }

    50% {
        transform: translateX(7px);
    }

    75% {
        transform: translateX(-4px);
    }
}

.progress-widget {
    position: fixed;
    right: 24px;
    bottom: 24px;
    width: 235px;
    padding: 17px;
    z-index: 50;
    border: 1px solid rgba(108, 76, 255, 0.10);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 16px 45px rgba(47, 39, 100, 0.14);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.progress-widget-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 13px;
}

.progress-widget-icon {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    background: var(--violet-soft);
    color: var(--violet);
}

.progress-widget h3 {
    font-family: "Space Grotesk", sans-serif;
    font-size: 0.88rem;
    font-weight: 700;
}

.progress-widget p {
    color: var(--muted);
    font-size: 0.69rem;
}

.progress-stats {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
}

.progress-stat {
    flex: 1;
    padding: 9px;
    border-radius: 12px;
    background: #f8f7fc;
}

.progress-stat-value {
    display: block;
    color: var(--ink-soft);
    font-family: "Space Grotesk", sans-serif;
    font-size: 0.78rem;
    font-weight: 600;
}

.mini-progress {
    width: 100%;
    height: 6px;
    overflow: hidden;
    border-radius: 999px;
    background: #e9e8f1;
}

#widget-progress-fill {
    width: 0%;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--violet), var(--blue));
    transition: width 0.4s ease;
}

.progress-widget .microcopy {
    margin-top: 9px;
    color: var(--light-text);
    font-size: 0.67rem;
    text-align: center;
}

#screen-celebrate {
    min-height: calc(100vh - 110px);
    display: none;
    align-items: center;
    justify-content: center;
    text-align: center;
}

#screen-celebrate.active {
    display: flex;
}

.celebrate-card {
    max-width: 650px;
    padding: 55px 40px;
    border: 1px solid rgba(108, 76, 255, 0.10);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.89);
    box-shadow: var(--shadow-card);
}

.celebrate-icon {
    width: 88px;
    height: 88px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 23px;
    border-radius: 28px;
    background: linear-gradient(135deg, var(--violet-soft), var(--coral-soft));
    color: var(--violet);
    font-size: 2.35rem;
    animation: celebrateFloat 2.5s ease-in-out infinite;
}

@keyframes celebrateFloat {
    0%,
    100% {
        transform: translateY(0) rotate(-2deg);
    }

    50% {
        transform: translateY(-7px) rotate(2deg);
    }
}

#screen-celebrate .badge {
    margin-bottom: 18px;
}

#screen-celebrate h2 {
    margin-bottom: 13px;
}

#screen-celebrate p {
    max-width: 500px;
    margin: 0 auto 28px;
    color: var(--ink-soft);
    font-size: 0.98rem;
}

#btn-generate.loading {
    pointer-events: none;
}

#btn-generate.loading i {
    animation: spin 0.9s linear infinite;
}

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

.card-pop {
    animation: cardPop 0.5s cubic-bezier(.2, .8, .2, 1);
}

@keyframes cardPop {
    from {
        opacity: 0;
        transform: translateY(10px) scale(0.97);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}


/* =========================================
   DESKTOP TASK LIST
   ========================================= */

.desktop-task-panel {
    position: fixed;
    left: max(20px, calc(50% - 820px));
    top: 50%;
    transform: translateY(-50%);
    width: 210px;
    max-height: 70vh;
    z-index: 40;

    overflow-y: auto;
    overflow-x: hidden;

    padding-right: 6px;
}

.desktop-task-panel::-webkit-scrollbar {
    width: 6px;
}

.desktop-task-panel::-webkit-scrollbar-track {
    background: transparent;
}

.desktop-task-panel::-webkit-scrollbar-thumb {
    background: rgba(108, 76, 255, 0.35);
    border-radius: 999px;
}

.desktop-task-panel::-webkit-scrollbar-thumb:hover {
    background: rgba(108, 76, 255, 0.55);
}

.desktop-task-header {
    margin-bottom: 15px;
}

.desktop-task-label {
    display: block;
    margin-bottom: 5px;
    color: var(--violet);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 1.5px;
}

.desktop-task-header h3 {
    color: var(--ink);
    font-family: "Space Grotesk", sans-serif;
    font-size: 1.15rem;
    margin: 0;
}

.desktop-task-list {
    display: flex;
    flex-direction: column;
    gap: 9px;
}

.desktop-task-step {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 48px;
    padding: 11px 12px;
    border: 1px solid var(--border);
    border-radius: 13px;
    background: rgba(255, 255, 255, 0.84);
    color: var(--muted);
    font-size: 0.8rem;
    box-shadow: 0 7px 20px rgba(54, 47, 115, 0.05);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.desktop-task-step.active {
    border-color: rgba(108, 76, 255, 0.28);
    background: linear-gradient(135deg, var(--violet-soft), #ffffff);
    color: var(--ink);
    box-shadow: 0 9px 24px rgba(108, 76, 255, 0.10);
}

.desktop-task-step.completed {
    border-color: rgba(57, 185, 130, 0.20);
    background: #f2fbf7;
    color: var(--ink-soft);
}

.desktop-task-number {
    width: 27px;
    height: 27px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(77, 131, 255, 0.15);
    border-radius: 9px;
    background: #f4f5fb;
    color: var(--muted);
    font-family: "Space Grotesk", sans-serif;
    font-size: 0.72rem;
    font-weight: 700;
}

.desktop-task-step.active .desktop-task-number {
    border-color: transparent;
    background: var(--violet);
    color: var(--white);
    box-shadow: 0 5px 13px rgba(108, 76, 255, 0.22);
}

.desktop-task-step.completed .desktop-task-number {
    border-color: rgba(57, 185, 130, 0.15);
    background: #e4f7ef;
    color: #29996d;
}

.desktop-task-text {
    min-width: 0;
    line-height: 1.35;
}

.desktop-task-step.active .desktop-task-text {
    font-weight: 700;
}

.desktop-task-check {
    display: none;
    margin-left: auto;
    color: #39b982;
    font-size: 0.75rem;
}

.desktop-task-step.completed .desktop-task-check {
    display: block;
}


/* =========================================
   DESKTOP QUOTE
   ========================================= */

.desktop-quote {
    position: fixed;
    right: max(20px, calc(50% - 820px));
    top: 32%;
    width: 235px;
    z-index: 40;
    text-align: left;
    transform: rotate(-3deg);
}

.desktop-quote p {
    margin: 0 0 7px;
    color: var(--violet);
    font-family: "Caveat", cursive;
    font-size: 2rem;
    font-weight: 600;
    line-height: 1.2;
    background: linear-gradient(
        135deg,
        var(--violet),
        var(--blue),
        var(--coral)
    );
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.desktop-quote span {
    color: var(--muted);
    font-family: "Caveat", cursive;
    font-size: 1rem;
    font-weight: 500;
}


/* =========================================
   RESPONSIVE
   ========================================= */

@media (max-width: 800px) {
    .app-container {
        padding: 28px 16px 115px;
    }

    .progress-widget {
        left: 16px;
        right: 16px;
        bottom: 14px;
        width: auto;
    }

    .desktop-task-panel,
    .desktop-quote {
        display: none;
    }

    #screen-input,
    #screen-list,
    #screen-focus {
        margin-top: 30px;
    }

    .action-map-header {
        align-items: flex-start;
    }

    .action-map-decoration {
        display: none;
    }

    .focus-card {
        padding: 35px 23px;
    }
}

@media (max-width: 520px) {
    h1 {
        font-size: 2.65rem;
    }

    h2 {
        font-size: 2rem;
    }

    .hero-icon {
        width: 76px;
        height: 76px;
        border-radius: 23px;
        font-size: 1.9rem;
    }

    .input-card {
        padding: 19px;
    }

    .input-actions {
        flex-direction: column;
    }

    #btn-voice {
        width: 100%;
    }

    .detail-level-section {
        padding: 14px;
    }

    .detail-level-options {
        grid-template-columns: 1fr;
    }

    .detail-option {
        min-height: 68px;
        padding: 13px 14px;
    }

    .action-map-header {
        padding: 20px;
    }

    .steps-preview-container {
        padding: 8px 10px;
    }

    .preview-step {
        grid-template-columns: 38px minmax(0, 1fr) 24px;
        gap: 11px;
        padding: 15px 6px;
    }

    .preview-step-number {
        width: 36px;
        height: 36px;
        border-radius: 12px;
        font-size: 0.75rem;
    }

    .preview-step-label {
        font-size: 0.58rem;
    }

    .preview-step-text {
        font-size: 0.88rem;
        line-height: 1.45;
    }

    .action-map-footer {
        flex-direction: column;
        align-items: stretch;
        padding: 17px 20px 20px;
    }

    .action-map-footer-hint {
        justify-content: center;
    }

    .action-map-footer .primary-button {
        width: 100%;
    }

    .focus-step-text {
        font-size: 1.3rem;
    }

    .celebrate-card {
        padding: 42px 23px;
    }
}

button:focus-visible,
input:focus-visible {
    outline: 3px solid rgba(77, 131, 255, 0.35);
    outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}