/* ===== Tap.IA no canto + formulário de cotação (bottom sheet) ===== */
.tapia-fab { position: fixed; right: 22px; bottom: 22px; z-index: 80; display: flex; align-items: flex-end; gap: 12px; }
.tapia-bubble { position: relative; max-width: 240px; padding: 12px 14px; border-radius: 16px 16px 4px 16px; background: rgba(6,20,16,0.92); backdrop-filter: blur(12px); border: 1px solid rgba(57,181,74,0.4); color: #f2f7f3; font-size: 13px; line-height: 1.45; box-shadow: 0 16px 40px rgba(0,0,0,0.45); opacity: 0; transform: translateY(8px) scale(0.96); transition: opacity .4s ease, transform .4s ease; pointer-events: none; }
.tapia-bubble.is-on { opacity: 1; transform: none; pointer-events: auto; }
.tapia-bubble b { color: #9df0a8; font-family: var(--display); }
.tapia-bubble .x { position: absolute; top: -8px; right: -8px; width: 22px; height: 22px; border-radius: 50%; border: 1px solid rgba(57,181,74,0.4); background: #061410; color: #9df0a8; font-size: 12px; line-height: 20px; text-align: center; cursor: pointer; }
.tapia-avatar { position: relative; width: 150px; height: 190px; cursor: pointer; transition: transform .35s ease; filter: drop-shadow(0 18px 30px rgba(0,0,0,0.45)); }
.tapia-avatar:hover { transform: translateY(-4px) scale(1.03); }
.tapia-avatar::before { content: ""; position: absolute; left: 50%; bottom: 8px; width: 150px; height: 70px; transform: translateX(-50%); border-radius: 50%; background: radial-gradient(50% 50% at 50% 50%, rgba(57,181,74,0.75), rgba(57,181,74,0) 70%); filter: blur(6px); animation: glow 3s ease-in-out infinite; pointer-events: none; }
.tapia-avatar video, .tapia-avatar img { position: relative; width: 100%; height: 100%; object-fit: contain; object-position: 50% 100%; display: block; background: transparent; }
.tapia-avatar .tag { position: absolute; left: 50%; bottom: 0; transform: translateX(-50%); padding: 4px 10px; border-radius: 999px; background: #39b54a; color: #05150b; font-family: var(--display); font-size: 10px; font-weight: 700; letter-spacing: .14em; white-space: nowrap; box-shadow: 0 6px 16px rgba(0,0,0,0.35); }
@keyframes glow { 0%,100% { opacity: .7; transform: translateX(-50%) scale(1); } 50% { opacity: 1; transform: translateX(-50%) scale(1.12); } }
@keyframes ring { 0% { transform: scale(0.9); opacity: 1; } 100% { transform: scale(1.5); opacity: 0; } }
body.quote-open .tapia-fab { opacity: 0; pointer-events: none; }

/* Sheet */
.quote-backdrop { position: fixed; inset: 0; z-index: 90; background: rgba(3,11,8,0.6); backdrop-filter: blur(6px); opacity: 0; pointer-events: none; transition: opacity .4s ease; }
.quote-sheet { position: fixed; z-index: 95; left: 50%; bottom: 0; transform: translate(-50%, 105%); width: min(720px, 100%); max-height: 92vh; display: flex; flex-direction: column; background: linear-gradient(180deg, #0e2a1f, #07140e); border: 1px solid rgba(57,181,74,0.4); border-bottom: 0; border-radius: 28px 28px 0 0; box-shadow: 0 -30px 100px rgba(0,0,0,0.6); transition: transform .55s cubic-bezier(.2,.8,.2,1); }
body.quote-open .quote-backdrop { opacity: 1; pointer-events: auto; }
body.quote-open .quote-sheet { transform: translate(-50%, 0); }
.quote-head { display: flex; align-items: center; gap: 14px; padding: 18px 24px 12px; }
.quote-head .av { width: 52px; height: 52px; border-radius: 50%; overflow: hidden; border: 2px solid #39b54a; flex-shrink: 0; }
.quote-head .av video, .quote-head .av img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 25%; }
.quote-head h3 { font-family: var(--display); font-size: 1.15rem; font-weight: 700; letter-spacing: -0.01em; }
.quote-head p { color: var(--muted); font-size: 13px; margin-top: 2px; }
.quote-head .close { margin-left: auto; width: 38px; height: 38px; border-radius: 50%; border: 1px solid rgba(242,247,243,0.2); background: transparent; color: #f2f7f3; font-size: 18px; cursor: pointer; }
.quote-progress { height: 3px; margin: 0 24px; background: rgba(255,255,255,0.08); border-radius: 3px; overflow: hidden; }
.quote-progress i { display: block; height: 100%; width: 33%; background: linear-gradient(90deg, #9df0a8, #39b54a); transition: width .5s ease; }
.quote-steps { position: relative; overflow-y: auto; flex: 1; }
.quote-step { display: none; padding: 20px 24px 8px; animation: fade .45s ease; }
.quote-step.is-on { display: block; }
.quote-step h4 { font-family: var(--display); font-size: 1.4rem; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 4px; }
.quote-step h4 em { font-style: normal; color: #39b54a; }
.quote-step > p { color: var(--muted); font-size: 14px; margin-bottom: 16px; }
.qf { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.qf .full { grid-column: 1 / -1; }
.qf label { display: block; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.qf input, .qf select, .qf textarea { width: 100%; padding: 13px 15px; border-radius: 14px; border: 1px solid rgba(242,247,243,0.18); background: rgba(255,255,255,0.05); color: #f2f7f3; font-family: var(--body); font-size: 15px; outline: none; transition: border-color .25s; }
.qf input:focus, .qf select:focus, .qf textarea:focus { border-color: #39b54a; }
.qf select option { background: #0a1f17; }
.qf .ac { position: relative; }
.qf .ac-list { position: static; margin-top: 6px; background: rgba(6,20,16,0.9); border: 1px solid rgba(57,181,74,0.4); border-radius: 12px; overflow: hidden; display: none; max-height: 190px; overflow-y: auto; }
.qf .ac-list.is-open { display: block; }
.qf .ac-list button { display: flex; justify-content: space-between; width: 100%; text-align: left; padding: 9px 14px; border: 0; background: transparent; color: #f2f7f3; font-family: var(--body); font-size: 14px; cursor: pointer; }
.qf .ac-list button:hover { background: rgba(57,181,74,0.16); }
.qf .ac-list small { color: #39b54a; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; }
.qf .hint { font-size: 12px; color: #9df0a8; margin-top: 6px; min-height: 16px; }
.types { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; grid-column: 1 / -1; }
.types label { margin: 0; }
.types input { display: none; }
.types span { display: block; padding: 14px 12px; border-radius: 14px; border: 1px solid rgba(242,247,243,0.14); background: rgba(255,255,255,0.03); text-align: center; cursor: pointer; font-family: var(--display); font-size: 13px; font-weight: 600; color: #f2f7f3; text-transform: none; letter-spacing: 0; transition: all .2s; }
.types span small { display: block; font-family: var(--body); font-weight: 400; font-size: 11px; color: var(--muted); margin-top: 3px; }
.types input:checked + span { border-color: #39b54a; background: rgba(57,181,74,0.16); box-shadow: 0 0 0 1px #39b54a inset; }
.quote-foot { display: flex; align-items: center; gap: 10px; padding: 14px 24px 22px; border-top: 1px solid rgba(255,255,255,0.06); }
.quote-foot .spacer { flex: 1; }
.quote-foot .err { color: #ff9b8d; font-size: 13px; }
.quote-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 16px; padding: 14px; border-radius: 14px; background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.06); font-size: 13px; margin-bottom: 14px; }
.quote-summary div span { display: block; font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.quote-done { text-align: center; padding: 30px 24px 40px; }
.quote-done .proto { display: inline-block; margin: 14px 0; padding: 12px 22px; border-radius: 999px; background: rgba(57,181,74,0.16); border: 1px solid #39b54a; font-family: var(--display); font-weight: 800; font-size: 1.4rem; letter-spacing: .04em; color: #9df0a8; }
.quote-done p { color: var(--muted); font-size: 14px; line-height: 1.6; max-width: 440px; margin: 0 auto; }
.hp { position: absolute; left: -9999px; opacity: 0; height: 0; }
@media (max-width: 720px) {
  .tapia-fab { right: 14px; bottom: 14px; }
  .tapia-avatar { width: 104px; height: 132px; }
  .tapia-avatar::before { width: 104px; height: 50px; }
  .tapia-bubble { max-width: 200px; font-size: 12px; }
  .quote-sheet { border-radius: 22px 22px 0 0; max-height: 94vh; }
  .qf { grid-template-columns: 1fr; }
  .types { grid-template-columns: 1fr; }
  .quote-summary { grid-template-columns: 1fr; }
}

.qf .ac-list button.is-active { background: rgba(57,181,74,0.22); }
.qf .ok { border-color: #39b54a !important; box-shadow: 0 0 0 2px rgba(57,181,74,0.18); }

/* ===== TAPIA: dourado, pilares e chat ===== */
:root { --gold: #c9a75b; --gold2: #f3d98d; }
.kicker.gold { color: var(--gold2); }
.gold-text { color: var(--gold2); }
.pillars { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 22px; }
.pillars li { padding: 14px 16px; border-radius: 14px; border: 1px solid rgba(201,167,91,0.3); background: rgba(201,167,91,0.06); }
.pillars b { display: block; font-family: var(--display); font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: var(--gold2); margin-bottom: 4px; }
.pillars span { color: var(--muted); font-size: 13px; line-height: 1.5; }
.traits { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 16px; }
.traits span { padding: 6px 12px; border-radius: 999px; border: 1px solid rgba(201,167,91,0.4); color: var(--gold2); font-family: var(--display); font-size: 10px; letter-spacing: .16em; text-transform: uppercase; }
.tapia-avatar .tag { background: linear-gradient(135deg, var(--gold2), var(--gold)); color: #1a1405; }
.tapia-bubble { border-color: rgba(201,167,91,0.45); }
.tapia-bubble b { color: var(--gold2); }
.tapia-chat { position: absolute; right: 0; bottom: calc(100% + 12px); width: min(360px, calc(100vw - 28px)); background: linear-gradient(180deg, #0b2a20, #061410); border: 1px solid rgba(201,167,91,0.45); border-radius: 22px; box-shadow: 0 30px 80px rgba(0,0,0,0.55); overflow: hidden; display: none; flex-direction: column; animation: fade .35s ease; }
.tapia-chat.is-on { display: flex; }
.tc-head { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-bottom: 1px solid rgba(201,167,91,0.25); background: rgba(201,167,91,0.06); }
.tc-head img { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; object-position: 50% 25%; border: 2px solid var(--gold); }
.tc-head b { display: block; font-family: var(--display); font-size: 14px; letter-spacing: .08em; color: var(--gold2); }
.tc-head span { display: flex; align-items: center; gap: 6px; font-size: 11px; color: var(--muted); }
.tc-head span i { width: 7px; height: 7px; border-radius: 50%; background: #39b54a; box-shadow: 0 0 8px #39b54a; }
.tc-close { margin-left: auto; width: 30px; height: 30px; border-radius: 50%; border: 1px solid rgba(242,247,243,0.2); background: transparent; color: #f2f7f3; cursor: pointer; font-size: 16px; }
.tc-body { padding: 14px; display: flex; flex-direction: column; gap: 10px; max-height: 50vh; overflow-y: auto; }
.tc-msg { align-self: flex-start; max-width: 92%; padding: 10px 14px; border-radius: 14px 14px 14px 4px; background: #f2f7f3; color: #08150f; font-size: 13px; line-height: 1.5; }
.tc-msg.me { align-self: flex-end; border-radius: 14px 14px 4px 14px; background: rgba(57,181,74,0.25); color: #f2f7f3; }
.tc-msg b { color: #136337; }
.tc-msg.me b { color: #9df0a8; }
.tc-actions { display: grid; gap: 6px; }
.tc-actions button { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; border: 1px solid rgba(201,167,91,0.35); background: rgba(255,255,255,0.03); color: #f2f7f3; font-family: var(--body); font-size: 13px; text-align: left; cursor: pointer; transition: all .2s; }
.tc-actions button:hover { border-color: var(--gold2); background: rgba(201,167,91,0.12); transform: translateX(2px); }
.tc-actions button span { width: 26px; height: 26px; border-radius: 8px; background: rgba(201,167,91,0.15); display: grid; place-items: center; font-size: 13px; }
.tc-input { display: flex; gap: 8px; padding: 10px 12px; border-top: 1px solid rgba(201,167,91,0.25); }
.tc-input input { flex: 1; padding: 10px 14px; border-radius: 999px; border: 1px solid rgba(242,247,243,0.18); background: rgba(255,255,255,0.05); color: #f2f7f3; font-family: var(--body); font-size: 13px; outline: none; }
.tc-input input:focus { border-color: var(--gold); }
.tc-input button { width: 40px; height: 40px; border-radius: 50%; border: 0; background: linear-gradient(135deg, var(--gold2), var(--gold)); color: #1a1405; cursor: pointer; font-size: 14px; }
body.quote-open .tapia-chat { display: none; }
@media (max-width: 720px) { .pillars { grid-template-columns: 1fr; } .tapia-chat { right: -14px; width: calc(100vw - 20px); } }
