/* ADSTA PWA 0.11.1 — Ask AD voice-acts, meal/activity/neither verdict, Google Calendar ask, signed-out welcome. */

/* ---------- Ask AD ---------- */
.x-ai-topr { display: flex; align-items: center; gap: 8px; min-width: 40px; justify-content: flex-end; }
.x-ai-x.sm { width: 36px; height: 36px; display: grid; place-items: center; }
.x-ai-x.off { opacity: .5; }
.x-ai-hello em { font-style: normal; color: #FFC9A8; font-weight: 600; }
.x-caps { position: relative; z-index: 2; margin-top: auto; padding: 0 16px 10px; display: grid; gap: 6px; }
.x-caps[hidden] { display: none; }
.x-cap { display: flex; gap: 8px; align-items: flex-start; font-size: 13.5px; line-height: 1.4; padding: 9px 12px; border-radius: 16px; max-width: 92%;
  background: rgba(14,4,5,.62); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); animation: xcapin .25s ease both; }
.x-cap.me { justify-self: end; background: rgba(170,0,3,.85); }
.x-cap b { flex: none; width: 20px; height: 20px; border-radius: 50%; background: var(--inferno); display: grid; place-items: center; font-size: 8px; margin-top: 1px; }
@keyframes xcapin { from { opacity: 0; transform: translateY(6px); } }
.x-caps:not([hidden]) ~ .x-ai-bottom, .x-caps:not([hidden]) ~ .x-ai-result { margin-top: 0; }
.x-listen { justify-self: center; display: flex; align-items: center; gap: 8px; font-size: 12.5px; padding: 7px 14px; border-radius: 999px; background: rgba(0,0,0,.4); max-width: 100%; white-space: nowrap; overflow: hidden; }
.x-listen .dot { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,.35); flex: none; }
.x-listen .dot.on { background: #FF6B6B; animation: xblink 1s infinite; }
.x-listen .t { overflow: hidden; text-overflow: ellipsis; }
.x-cmds { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; }
.x-cmds button { border: 1px solid rgba(255,255,255,.28); background: rgba(255,255,255,.12); color: #fff; font: inherit; font-size: 12.5px; font-weight: 600; padding: 8px 13px; border-radius: 999px; cursor: pointer; }
.x-cmds button:first-child { background: #fff; color: var(--cherry, #6E0002); border-color: #fff; }
.x-ai-bottom.slim .x-ai-controls, .x-ai-bottom.slim .x-ai-modes, .x-ai-bottom.slim .x-ai-type, .x-ai-bottom.slim .x-cmds { display: none; }
.x-count { position: absolute; inset: 0; z-index: 3; display: grid; place-content: center; justify-items: center; pointer-events: none; gap: 4px; color: #fff; }
.x-count[hidden] { display: none; }
.x-count b { font-size: 120px; line-height: 1; font-weight: 700; text-shadow: 0 6px 30px rgba(0,0,0,.45); animation: xcount .9s ease both; }
.x-count span { font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
@keyframes xcount { 0% { transform: scale(1.6); opacity: 0; } 25% { transform: scale(1); opacity: 1; } 85% { opacity: 1; } 100% { opacity: 0; transform: scale(.9); } }
.x-flash { position: absolute; inset: 0; z-index: 4; background: #fff; pointer-events: none; animation: xflash .45s ease both; }
.x-flash[hidden] { display: none; }
@keyframes xflash { from { opacity: .95; } to { opacity: 0; } }
.x-recring { position: absolute; inset: 0; z-index: 1; pointer-events: none; box-shadow: inset 0 0 0 4px rgba(255,59,59,.85); animation: xblink 1.4s infinite; }
.x-recring[hidden] { display: none; }
.x-ai-card .c { text-align: center; align-self: center; }
.x-ai-card > .x-spin { align-self: center; margin: 6px 0; }
.x-clsrow { display: flex; align-items: center; justify-content: space-between; }
.x-cls { display: inline-flex; align-items: center; gap: 6px; font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; padding: 5px 9px; border-radius: 999px; }
.x-cls i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.x-cls.food { background: #FFEDD5; color: #8A4A00; }
.x-cls.activity { background: #E3F3EA; color: #1F8A5B; }
.x-cls.none { background: #F1ECEA; color: #6B6667; }
.x-conf { font-size: 11px; color: var(--muted); }
.x-tags { display: flex; flex-wrap: wrap; gap: 4px; margin: 4px 0; }
.x-tags span { font-size: 11px; padding: 3px 8px; border-radius: 999px; background: #F8F4F2; border: 1px solid var(--line); }
.x-row2 { display: flex; gap: 8px; margin-top: 10px; }
.x-row2 .btn { flex: 1; }
.x-row2 .btn-primary { flex: 2; }
.x-sayhint { align-self: center; margin-top: 8px; font-size: 11px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.x-sayhint::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #FF6B6B; animation: xblink 1s infinite; }
.x-bub .x-row2 .btn { padding: 7px 10px; font-size: 12px; }

/* ---------- Google Calendar ask ---------- */
.x-calask { text-align: center; padding: 6px 4px 4px; }
.x-calask h3 { margin: 10px 0 4px; font-size: 18px; }
.x-calask .fine { margin: 8px 0 12px; }
.x-calask .btn-block { margin-top: 12px; }
.x-calico { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; margin: 0 auto; background: #FFEDD5; color: var(--inferno); }
.x-calico.delete { background: #F1ECEA; color: var(--charcoal); }
.x-calrem { display: flex; gap: 8px; align-items: center; justify-content: center; margin-top: 12px; font-size: 12px; color: var(--muted); }
.x-calrow { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.x-calrow strong { display: block; font-size: 13px; }
.x-calrow small { display: block; font-size: 11.5px; color: var(--muted); }

/* ---------- signed-out welcome ---------- */
.app.x-guest-home .topbar, .app.x-guest-home .tabbar { display: none; }
.x-welcome { position: absolute; inset: 0; padding: 0 !important; background: #120304; color: #fff; overflow: hidden; animation: none; }
.x-wslide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.2s ease; }
.x-wslide.on { opacity: 1; }
.x-wslide img { width: 100%; height: 100%; object-fit: cover; }
.x-wslide.on img { animation: xkb 7s ease-out both; }
@keyframes xkb { from { transform: scale(1.14); } to { transform: scale(1.02); } }
.x-wscrim { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(18,3,4,.55) 0%, rgba(18,3,4,0) 24%, rgba(18,3,4,.1) 46%, rgba(18,3,4,.9) 80%, #120304 100%); }
.x-wbars { position: absolute; top: calc(env(safe-area-inset-top,0px) + 14px); left: 16px; right: 16px; display: flex; gap: 4px; }
.x-wbars i { flex: 1; height: 3px; border-radius: 3px; background: rgba(255,255,255,.3); position: relative; overflow: hidden; }
.x-wbars i.past { background: #fff; }
.x-wbars i.on::after { content: ""; position: absolute; inset: 0; background: #fff; transform-origin: left; animation: xbar 5s linear both; }
@keyframes xbar { from { transform: scaleX(0); } }
.x-welcome::before { content: "ADSTA"; position: absolute; z-index: 2; top: calc(env(safe-area-inset-top,0px) + 30px); left: 20px; font-weight: 700; letter-spacing: .26em; font-size: 15px; }
.x-wbody { position: absolute; left: 0; right: 0; bottom: 0; padding: 0 22px calc(env(safe-area-inset-bottom,0px) + 22px); display: grid; gap: 10px; }
.x-weye { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; font-weight: 600; color: #FFC9A8; animation: xcapin .4s ease both; }
.x-wh { margin: 0; font-size: 36px; line-height: 1.05; font-weight: 700; letter-spacing: -.02em; text-wrap: balance; animation: xcapin .5s ease both; color: #fff; }
.x-wsub { margin: 0 0 6px; font-size: 14px; line-height: 1.5; opacity: .85; max-width: 34ch; animation: xcapin .6s ease both; }
.x-wbtn { height: 50px; font-size: 15px; }
.x-wghost { background: rgba(255,255,255,.12) !important; border-color: rgba(255,255,255,.3) !important; color: #fff !important; }
.x-wfine { font-size: 11.5px; opacity: .65; text-align: center; margin: 2px 0 0; }
.x-wfine .link { color: #fff; text-decoration: underline; }

/* sheets (e.g. the Google Calendar question) must sit above the Ask AD overlay */
.sheet-wrap { z-index: 90; }
