|
| 1 | +/* ========================================================= |
| 2 | + Kernel entrance animation — styles for the chat empty-state. |
| 3 | + Scoped under #empty-state so it never leaks into the chat. |
| 4 | + ========================================================= */ |
| 5 | + |
| 6 | +/* The low-poly globe is a full-screen backdrop behind the whole app. */ |
| 7 | +#globe { |
| 8 | + position: fixed; |
| 9 | + inset: 0; |
| 10 | + width: 100%; |
| 11 | + height: 100%; |
| 12 | + display: block; |
| 13 | + z-index: 0; |
| 14 | + pointer-events: none; |
| 15 | +} |
| 16 | + |
| 17 | +/* Keep all the real UI above the globe backdrop. */ |
| 18 | +.app { |
| 19 | + position: relative; |
| 20 | + z-index: 1; |
| 21 | +} |
| 22 | + |
| 23 | +/* During the entrance the empty-state is a full-screen overlay so the title |
| 24 | + can sit to the RIGHT of the full-viewport globe (desktop) / BELOW it |
| 25 | + (mobile), matching the original layout. It's click-through except the pill; |
| 26 | + the chat hides it (display:none) once a conversation starts. */ |
| 27 | +#empty-state { |
| 28 | + position: fixed; |
| 29 | + inset: 0; |
| 30 | + z-index: 2; |
| 31 | + display: flex; |
| 32 | + flex-direction: row; |
| 33 | + align-items: center; |
| 34 | + justify-content: flex-end; /* title to the right */ |
| 35 | + gap: 0; |
| 36 | + padding: 0 18vw; |
| 37 | + pointer-events: none; |
| 38 | +} |
| 39 | + |
| 40 | +/* Chrome that stays blank until the entrance reveals it (badge + input). |
| 41 | + Set in CSS so there's no flash before entrance.js runs; entrance.js |
| 42 | + animates it in (or reveals it instantly if GSAP is unavailable). */ |
| 43 | +.entrance-init-hidden { |
| 44 | + opacity: 0; |
| 45 | + visibility: hidden; |
| 46 | +} |
| 47 | + |
| 48 | +/* Title stack (revealed by GSAP). Left-aligned on the right side (desktop). */ |
| 49 | +.entrance-content { |
| 50 | + position: relative; |
| 51 | + z-index: 1; |
| 52 | + display: flex; |
| 53 | + flex-direction: column; |
| 54 | + align-items: flex-start; |
| 55 | + text-align: left; |
| 56 | + max-width: 460px; |
| 57 | + opacity: 0; |
| 58 | + transform: translateY(18px); |
| 59 | +} |
| 60 | + |
| 61 | +.entrance-eyebrow { |
| 62 | + font-size: 0.72rem; |
| 63 | + letter-spacing: 0.42em; |
| 64 | + font-weight: 600; |
| 65 | + color: #ffffff; |
| 66 | + opacity: 0.85; |
| 67 | + margin-bottom: 14px; |
| 68 | +} |
| 69 | + |
| 70 | +.entrance-headline { |
| 71 | + font-size: clamp(1.9rem, 4.4vw, 3rem); |
| 72 | + line-height: 1.12; |
| 73 | + font-weight: 700; |
| 74 | + letter-spacing: -0.01em; |
| 75 | + background: linear-gradient(120deg, #ffffff 0%, #d9dadf 45%, #a9aab0 100%); |
| 76 | + -webkit-background-clip: text; |
| 77 | + background-clip: text; |
| 78 | + color: transparent; |
| 79 | + padding-bottom: 5px; |
| 80 | +} |
| 81 | + |
| 82 | +/* "Kernel" inside the headline — matches the mono entrance choice. */ |
| 83 | +.entrance-kernel { |
| 84 | + -webkit-background-clip: text; |
| 85 | + background-clip: text; |
| 86 | + -webkit-text-fill-color: #b91c1c; |
| 87 | + color: #b91c1c; |
| 88 | +} |
| 89 | + |
| 90 | +/* Blinking caret following the typed title. */ |
| 91 | +.entrance-caret { |
| 92 | + display: inline-block; |
| 93 | + width: 3px; |
| 94 | + height: 1em; |
| 95 | + margin-left: 4px; |
| 96 | + vertical-align: -0.12em; |
| 97 | + background: #e6e7ea; |
| 98 | + border-radius: 2px; |
| 99 | + box-shadow: 0 0 12px #e6e7ea; |
| 100 | + animation: entrance-blink 1s steps(1) infinite; |
| 101 | +} |
| 102 | + |
| 103 | +/* -------- Cycling command suggestions (red pill, white text) -------- */ |
| 104 | +.entrance-suggestion-wrap { |
| 105 | + margin-top: 22px; |
| 106 | + min-height: 2.4em; /* reserve space so the layout never jumps */ |
| 107 | +} |
| 108 | + |
| 109 | +.entrance-suggestion { |
| 110 | + display: inline-flex; |
| 111 | + align-items: center; |
| 112 | + max-width: 100%; |
| 113 | + padding: 8px 14px; |
| 114 | + border-radius: 12px; |
| 115 | + background: #b91c1c; |
| 116 | + color: #ffffff; |
| 117 | + font-family: var(--font-mono, 'JetBrains Mono', monospace); |
| 118 | + font-size: clamp(0.82rem, 1.6vw, 1rem); |
| 119 | + font-weight: 500; |
| 120 | + line-height: 1.3; |
| 121 | + letter-spacing: 0.01em; |
| 122 | + box-shadow: 0 8px 22px rgba(185, 28, 28, 0.35); |
| 123 | + cursor: pointer; /* click to drop the suggestion into the input */ |
| 124 | + pointer-events: auto; /* re-enable clicks (overlay is click-through) */ |
| 125 | +} |
| 126 | + |
| 127 | +.entrance-suggestion-text { |
| 128 | + white-space: nowrap; |
| 129 | +} |
| 130 | + |
| 131 | +.entrance-suggestion-caret { |
| 132 | + display: inline-block; |
| 133 | + width: 2px; |
| 134 | + height: 1.05em; |
| 135 | + margin-left: 3px; |
| 136 | + vertical-align: -0.12em; |
| 137 | + background: #ffffff; |
| 138 | + border-radius: 1px; |
| 139 | + animation: entrance-blink 1s steps(1) infinite; |
| 140 | +} |
| 141 | + |
| 142 | +@keyframes entrance-blink { |
| 143 | + 0%, 49% { opacity: 1; } |
| 144 | + 50%, 100% { opacity: 0; } |
| 145 | +} |
| 146 | + |
| 147 | +/* Mobile: globe sits up top, title stacks centered below it. */ |
| 148 | +@media (max-width: 820px) { |
| 149 | + #empty-state { |
| 150 | + align-items: flex-end; |
| 151 | + justify-content: center; |
| 152 | + padding: 0 7vw 24vh; /* lift the title above the input */ |
| 153 | + } |
| 154 | + |
| 155 | + .entrance-content { |
| 156 | + align-items: center; |
| 157 | + text-align: center; |
| 158 | + max-width: 560px; |
| 159 | + } |
| 160 | +} |
| 161 | + |
| 162 | +/* -------- "Thinking" indicator: a small globe spinner + label -------- */ |
| 163 | +.thinking-indicator { |
| 164 | + display: inline-flex; |
| 165 | + align-items: center; |
| 166 | + gap: 8px; |
| 167 | +} |
| 168 | + |
| 169 | +.thinking-globe { |
| 170 | + width: 30px; |
| 171 | + height: 30px; |
| 172 | + display: block; |
| 173 | + flex: 0 0 auto; |
| 174 | +} |
| 175 | + |
| 176 | +@media (prefers-reduced-motion: reduce) { |
| 177 | + .entrance-caret, |
| 178 | + .entrance-suggestion-caret { |
| 179 | + animation: none; |
| 180 | + } |
| 181 | +} |
0 commit comments