
:root {
  --ink: #15112e;
  --muted: #706886;
  --purple: #7436df;
  --purple-dark: #5122a8;
  --pink: #ff5a91;
  --yellow: #ffd76b;
  --blue: #4d9cf7;
  --green: #20bf78;
  --surface: #fff;
  --soft: #f6f3fb;
  --line: #e9e1f1;
  --shadow: 0 20px 55px rgba(54, 29, 87, .12);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: #f7f5fb;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.55;
}
button, input, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 3px solid #1c8cff;
  outline-offset: 3px;
}
.container { width: min(1120px, calc(100% - 40px)); margin: auto; }
.site-header { background: rgba(255,255,255,.96); border-bottom: 1px solid var(--line); position: relative; z-index: 20; }
.site-nav { min-height: 82px; display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.logo { width: 224px; height: 64px; object-fit: contain; display: block; }
.nav-links { display: flex; align-items: center; gap: 28px; font-weight: 750; font-size: 14px; }
.button { border: 0; border-radius: 14px; padding: 13px 21px; background: var(--purple); color: #fff; font-weight: 800; display: inline-flex; align-items: center; justify-content: center; gap: 8px; box-shadow: 0 5px 0 var(--purple-dark); transition: transform .15s, filter .15s; }
.button:hover { transform: translateY(-2px); filter: brightness(1.04); }
.button.secondary { background: #f1e8ff; color: var(--purple-dark); box-shadow: none; }
.button.small { padding: 10px 15px; border-radius: 24px; font-size: 14px; }
.eyebrow { margin: 0 0 9px; color: #7d3bc1; font-size: 12px; letter-spacing: 1.4px; font-weight: 900; text-transform: uppercase; }
.muted { color: var(--muted); }
.badge { display: inline-flex; align-items: center; gap: 6px; background: rgba(255,255,255,.72); border: 1px solid rgba(255,255,255,.8); padding: 7px 11px; border-radius: 999px; font-size: 13px; color: #644d75; }
.online-dot { width: 8px; height: 8px; background: var(--green); border-radius: 50%; display: inline-block; box-shadow: 0 0 0 4px rgba(32,191,120,.14); }

/* Principal */
.home-hero { background: linear-gradient(118deg, #eadcff 0%, #ffe5ef 56%, #fff0c8 100%); overflow: hidden; }
.home-hero-grid { display: grid; grid-template-columns: 1.08fr .92fr; gap: 72px; align-items: center; padding: 62px 0; }
.home-hero h1 { font-size: clamp(43px, 5vw, 67px); line-height: 1.03; letter-spacing: -3.7px; margin: 13px 0 23px; max-width: 640px; }
.home-hero h1 span { color: var(--purple); }
.home-hero-copy > p { color: #6e5878; font-size: 18px; max-width: 530px; }
.vibe-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 25px 0 16px; }
.hero-card { background: #fff; border: 2px solid #fff; border-radius: 27px; padding: 31px; box-shadow: 11px 12px 0 rgba(169, 104, 198, .22); transform: rotate(1deg); }
.hero-card > * { transform: rotate(-1deg); }
.hero-card h2 { margin: 13px 0 5px; font-size: 29px; letter-spacing: -1px; }
.hero-card p { margin: 0 0 20px; color: var(--muted); }
label { display: block; font-size: 14px; font-weight: 800; margin-bottom: 7px; }
input, textarea { width: 100%; border: 1px solid #d9cce7; border-radius: 13px; padding: 14px 15px; background: #fdfbff; color: var(--ink); }
.hero-card .button { width: 100%; margin-top: 12px; padding: 16px; }
.text-link { display: block; text-align: center; margin-top: 18px; color: #72548a; font-size: 14px; text-decoration: underline; text-underline-offset: 4px; }
.rooms-section { padding: 48px 0 60px; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 24px; }
.section-head h2 { font-size: 35px; letter-spacing: -1.4px; margin: 0 0 4px; }
.section-head p { margin: 0; }
.room-grid { display: grid; grid-template-columns: 1.15fr 1fr 1fr; gap: 18px; }
.room-card { border-radius: 22px; padding: 25px; min-height: 272px; display: flex; flex-direction: column; transition: transform .18s; }
.room-card:hover { transform: translateY(-4px); }
.room-card.purple { background: #eaddff; border: 1px solid #d2bcf8; }
.room-card.pink { background: #ffe1ec; }
.room-card.yellow { background: #ffedb1; }
.room-card-top, .room-card-bottom { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.room-icon { width: 58px; height: 58px; border-radius: 18px; display: grid; place-items: center; font-size: 31px; background: rgba(255,255,255,.65); }
.room-card h3 { font-size: 23px; line-height: 1.18; margin: 23px 0 6px; }
.room-card p { color: #685777; margin: 0; font-size: 14px; }
.room-card-bottom { margin-top: auto; align-items: end; }
.room-card-bottom small { color: #766585; max-width: 145px; }
.steps { background: #fff; border: 1px solid var(--line); border-radius: 21px; padding: 25px; display: grid; grid-template-columns: repeat(3,1fr); gap: 25px; margin-top: 36px; }
.step { display: flex; gap: 13px; }
.step-number { width: 35px; height: 35px; border-radius: 50%; flex: 0 0 auto; display: grid; place-items: center; font-weight: 900; background: #eadcff; color: #6a32b0; }
.step:nth-child(2) .step-number { background: #ffdbe7; color: #b32967; }
.step:nth-child(3) .step-number { background: #ffecad; color: #8c6500; }
.step strong { display: block; }
.step p { margin: 3px 0 0; color: var(--muted); font-size: 13px; }

/* Página da sala */
.breadcrumb { padding: 13px 0; font-size: 13px; color: #7a6d86; }
.room-landing { background: linear-gradient(135deg, #5322a8 0%, #8b3ae4 58%, #e95895 100%); color: #fff; position: relative; overflow: hidden; }
.room-landing:after { content: "☕"; position: absolute; font-size: 250px; right: 3%; top: 0; opacity: .09; transform: rotate(12deg); }
.room-landing-grid { min-height: 340px; display: grid; grid-template-columns: 1.1fr .9fr; gap: 70px; align-items: center; padding: 52px 0; position: relative; z-index: 1; }
.room-landing h1 { font-size: clamp(43px, 5vw, 64px); line-height: 1; letter-spacing: -3px; margin: 12px 0 16px; }
.room-landing p { color: #eee4ff; font-size: 17px; max-width: 600px; }
.avatars { display: flex; align-items: center; margin: 24px 0 9px; }
.avatars img, .avatar-emoji { width: 46px; height: 46px; border-radius: 15px; border: 3px solid #7b35d1; object-fit: cover; margin-left: -8px; background: #fff; display: grid; place-items: center; }
.avatars > :first-child { margin-left: 0; }
.room-mini-card { background: rgba(255,255,255,.15); border: 1px solid rgba(255,255,255,.22); border-radius: 22px; padding: 22px; backdrop-filter: blur(9px); }
.room-mini-card strong { font-size: 18px; display: block; }
.room-mini-card ul { padding-left: 20px; margin: 13px 0 0; color: #f3eaff; font-size: 14px; }
.join-section { padding: 36px 0 55px; }
.join-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(260px,.65fr); gap: 22px; align-items: start; }
.join-card, .aside-card { background: #fff; border: 1px solid var(--line); border-radius: 23px; padding: 28px; box-shadow: 0 10px 35px rgba(43,26,68,.06); }
.join-card h2 { font-size: 30px; letter-spacing: -1px; margin: 6px 0; }
.join-card .muted { margin-top: 0; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 17px; margin-top: 25px; }
.field.full { grid-column: 1/-1; }
.color-row { display: flex; gap: 10px; padding-top: 5px; }
.color-dot { width: 30px; height: 30px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 0 0 1px #cfc4d9; }
.color-dot.active { box-shadow: 0 0 0 3px var(--ink); }
.photo-drop { border: 1px dashed #c9b6dc; border-radius: 14px; padding: 14px; display: flex; align-items: center; justify-content: space-between; gap: 12px; color: var(--muted); }
.join-actions { display: flex; align-items: center; gap: 13px; margin-top: 24px; }
.join-actions .button { flex: 1; }
.aside-card + .aside-card { margin-top: 18px; }
.aside-card h3 { margin: 2px 0 7px; }
.aside-card p { margin: 0; color: var(--muted); font-size: 14px; }
.sponsor { background: #fff1bf; border: 0; }

/* Chat */
.chat-page { height: 100dvh; overflow: hidden; background: #f4f1f8; display: flex; flex-direction: column; }
.chat-header { min-height: 76px; background: #fff; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 245px minmax(0,1fr) 225px; align-items: center; gap: 18px; padding: 0 18px; }
.chat-header .logo { width: 196px; }
.chat-room-title { text-align: center; }
.chat-room-title strong { display: block; font-size: 17px; }
.chat-room-title small { color: var(--muted); }
.chat-header-actions { display: flex; justify-content: end; gap: 8px; }
.chat-shell { display: grid; grid-template-columns: 245px minmax(0,1fr) 230px; min-height: 0; flex: 1; }
.people-panel, .right-panel { background: #fff; padding: 18px 13px; overflow: auto; }
.people-panel { border-right: 1px solid var(--line); }
.right-panel { border-left: 1px solid var(--line); }
.panel-title { display: flex; align-items: center; justify-content: space-between; padding: 2px 9px 15px; font-size: 14px; font-weight: 900; }
.count { background: #eee1ff; color: #6b31b3; border-radius: 20px; padding: 1px 8px; }
.person { width: 100%; border: 0; display: flex; align-items: center; gap: 10px; padding: 10px 9px; border-radius: 14px; background: transparent; text-align: left; color: var(--ink); }
.person.active { background: #f0e5ff; }
.person-photo, .person-emoji { width: 41px; height: 41px; border-radius: 14px; object-fit: cover; flex: 0 0 auto; background: #ffe6ee; display: grid; place-items: center; font-size: 22px; }
.person b { display: block; font-size: 14px; }
.person small { display: block; color: var(--muted); font-size: 11px; }
.community-note { margin: 27px 8px 0; padding: 14px; background: #fff2c7; border-radius: 15px; font-size: 12px; color: #705c31; }
.chat-center { min-width: 0; display: flex; flex-direction: column; }
.conversation-bar { background: #fff; padding: 14px 20px; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; }
.conversation-bar b { display: block; }
.conversation-bar small { color: var(--muted); }
.messages { flex: 1; min-height: 0; overflow: auto; padding: 20px 25px; background: #faf8fd; }
.day-label { text-align: center; color: #90879b; font-size: 12px; }
.message { width: fit-content; max-width: 72%; background: #fff; border: 1px solid var(--line); border-radius: 6px 18px 18px 18px; padding: 11px 14px; margin: 14px 0; box-shadow: 0 2px 4px rgba(41,22,63,.03); }
.message.mine { margin-left: auto; background: #eadcff; border-color: #deccf7; border-radius: 18px 6px 18px 18px; }
.message-author { color: #8143bc; font-size: 12px; font-weight: 900; }
.message time { color: #9a90a4; font-weight: 500; margin-left: 7px; }
.message p { margin: 4px 0 0; }
.message img { width: min(240px, 100%); border-radius: 13px; display: block; margin-top: 8px; }
.audio-player { min-width: 260px; display: grid; grid-template-columns: 40px 1fr auto; align-items: center; gap: 10px; }
.audio-play { width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--purple); color: #fff; }
.wave { height: 28px; display: flex; gap: 3px; align-items: center; }
.wave i { width: 3px; border-radius: 5px; background: #9c75cc; display: block; }
.wave i:nth-child(3n+1) { height: 10px; }.wave i:nth-child(3n+2) { height: 21px; }.wave i:nth-child(3n) { height: 15px; }
.audio-player small { color: var(--muted); }
.composer { background: #fff; border-top: 1px solid var(--line); padding: 12px 17px; }
.composer-main { display: grid; grid-template-columns: auto minmax(0,1fr) auto; gap: 9px; align-items: center; }
.tool-button { border: 0; background: #f3edf9; color: #7043a0; width: 42px; height: 42px; border-radius: 13px; font-size: 20px; }
.composer textarea { resize: none; height: 46px; min-height: 46px; padding: 11px 14px; }
.composer-tools { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 7px; font-size: 12px; color: var(--muted); }
.composer-tools div { display: flex; gap: 6px; }
.composer-tools button { border: 0; background: transparent; color: #7640a4; font-weight: 700; padding: 4px 6px; }
.recording { display: none; align-items: center; gap: 12px; background: #ffe3ec; border: 1px solid #ffc4d8; padding: 10px 13px; border-radius: 15px; margin-bottom: 9px; }
.recording.show { display: flex; }
.recording .pulse { width: 11px; height: 11px; border-radius: 50%; background: #e12d68; animation: pulse 1s infinite; }
.recording strong { color: #b62458; }
.recording .record-time { margin-right: auto; }
.recording button { border: 0; background: #fff; border-radius: 10px; padding: 7px 10px; color: #7c3b59; font-weight: 800; }
@keyframes pulse { 50% { transform: scale(.6); opacity: .5; } }
.topic-card, .ad-card, .safety-card { border-radius: 18px; padding: 17px; }
.topic-card { background: #ffefb8; }
.topic-card small, .ad-card small { font-size: 10px; font-weight: 900; letter-spacing: 1px; }
.topic-card h3, .ad-card h3 { font-size: 17px; line-height: 1.3; margin: 10px 0 6px; }
.topic-card p, .ad-card p, .safety-card p { margin: 0; font-size: 12px; color: #726349; }
.topic-card button { margin-top: 12px; border: 0; background: rgba(255,255,255,.65); border-radius: 20px; padding: 8px 10px; font-weight: 800; color: #6e5625; }
.ad-card { border: 1px dashed #cab8dc; margin-top: 16px; background: #faf6ff; }
.safety-card { background: #e8dcff; margin-top: 16px; }
.safety-card p { color: #645374; }
.mobile-people { display: none; }
.screen-note { background: #fff0bd; color: #735e1e; text-align: center; font-size: 11px; padding: 5px 12px; }
.site-footer { background: #fff; border-top: 1px solid var(--line); padding: 24px 0; }
.footer-grid { display: flex; align-items: center; justify-content: space-between; gap: 25px; }
.footer-grid .logo { width: 190px; }
.footer-grid p { color: var(--muted); font-size: 12px; }

@media (max-width: 950px) {
  .home-hero-grid { gap: 32px; }
  .room-grid { grid-template-columns: 1fr 1fr; }
  .room-card:first-child { grid-column: 1/-1; min-height: 220px; }
  .chat-shell { grid-template-columns: 210px minmax(0,1fr); }
  .chat-header { grid-template-columns: 210px minmax(0,1fr) 160px; }
  .right-panel { display: none; }
}
@media (max-width: 720px) {
  .container { width: min(100% - 30px, 1120px); }
  .site-nav { min-height: 72px; }
  .site-nav .logo { width: 172px; height: 58px; }
  .nav-links a:not(.button) { display: none; }
  .nav-links { gap: 0; }
  .nav-links .button { padding: 10px 13px; font-size: 12px; }
  .home-hero-grid, .room-landing-grid, .join-grid { grid-template-columns: 1fr; }
  .home-hero-grid { padding: 37px 0 42px; gap: 34px; }
  .home-hero h1 { font-size: 48px; letter-spacing: -2.7px; }
  .hero-card { transform: none; padding: 23px; }
  .hero-card > * { transform: none; }
  .room-grid, .steps, .form-grid { grid-template-columns: 1fr; }
  .room-card:first-child, .field.full { grid-column: auto; }
  .steps { gap: 20px; }
  .section-head { display: block; }
  .room-landing-grid { padding: 35px 0; gap: 25px; }
  .room-landing h1 { font-size: 47px; }
  .join-actions { flex-direction: column; align-items: stretch; }
  .chat-header { min-height: 64px; grid-template-columns: 145px 1fr auto; padding: 0 10px; gap: 7px; }
  .chat-header .logo { width: 142px; height: 54px; }
  .chat-room-title strong { font-size: 14px; }
  .chat-room-title small { display: none; }
  .chat-header-actions .button.secondary { display: none; }
  .chat-header-actions .button { padding: 8px 10px; box-shadow: none; font-size: 11px; }
  .chat-shell { display: flex; position: relative; }
  .people-panel { display: none; }
  .people-panel.open { display: block; position: absolute; inset: 0 auto 0 0; width: 240px; z-index: 10; box-shadow: 10px 0 35px rgba(39,22,60,.2); }
  .chat-center { width: 100%; }
  .mobile-people { display: inline-flex; border: 0; border-radius: 20px; padding: 7px 10px; background: #eee1ff; color: #6633a5; font-weight: 800; }
  .conversation-bar { padding: 10px 12px; }
  .messages { padding: 12px; }
  .message { max-width: 90%; }
  .audio-player { min-width: 220px; }
  .composer { padding: 9px; }
  .composer-main { grid-template-columns: auto minmax(0,1fr) auto; }
  .composer-main .button { padding: 11px 12px; box-shadow: none; }
  .composer-tools { flex-wrap: wrap; gap: 4px; }
  .footer-grid { flex-direction: column; align-items: start; gap: 4px; }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
}

/* Integração com os dados e controles reais do sistema */
.chat-room.chat-page { width: 100%; }
.chat-header .chat-logo { display: flex; align-items: center; }
.room-picker-chat, .room-mobile-actions, .room-breadcrumb, .safety-strip, .sidebar-footer { display: none !important; }
.participants-head h2 { margin: 0; font: inherit; }
.participants-head > div { display: flex; align-items: center; gap: 6px; }
.participants-head [data-close-participants] { display: none; }
.participants-help { display: none; }
.participants-list { list-style: none; margin: 0; padding: 0; }
.participant-button { width: 100%; border: 0; display: flex; align-items: center; gap: 10px; padding: 10px 9px; border-radius: 14px; background: transparent; text-align: left; color: var(--ink); }
.participant-button.active { background: #f0e5ff; }
.participant-avatar { width: 41px; height: 41px; border-radius: 14px; object-fit: cover; flex: 0 0 auto; background: #ffe6ee; display: grid; place-items: center; overflow: hidden; font-weight: 900; }
.participant-avatar img { width: 100%; height: 100%; object-fit: cover; }
.participant-copy b { display: block; font-size: 14px; }
.participant-copy small { display: block; color: var(--muted); font-size: 11px; }
.messages .system-message, .messages .system-event { width: fit-content; max-width: 72%; background: #fff; border: 1px solid var(--line); border-radius: 6px 18px 18px 18px; padding: 11px 14px; margin: 14px 0; }
.system-message p { margin: 0 0 4px; display: flex; gap: 7px; color: #8143bc; font-size: 12px; }
.system-message time { color: #9a90a4; }
.messages .system-event { margin: 8px auto; border: 0; background: transparent; color: #90879b; font-size: 12px; text-align: center; }
.messages .message { width: fit-content; max-width: 72%; background: #fff; border: 1px solid var(--line); border-radius: 6px 18px 18px 18px; padding: 11px 14px; margin: 14px 0; box-shadow: 0 2px 4px rgba(41,22,63,.03); }
.messages .message.mine { margin-left: auto; background: #eadcff; border-color: #deccf7; border-radius: 18px 6px 18px 18px; }
.messages .message > p { margin: 0; }
.messages .message > div:last-child { margin-top: 4px; }
.messages .message.private-message { box-shadow: inset 3px 0 #ff5a91; }
.messages .message img { width: min(240px, 100%); border-radius: 13px; display: block; margin-top: 8px; }
.messages .message audio { width: min(290px, 100%); margin-top: 7px; }
.private-label { margin-left: 7px; color: #b32967; font-size: 10px; }
.composer-shell.composer { position: relative; }
.composer-shell .conversation-tabs { display: none; }
.composer-shell .private-controls { margin-bottom: 8px; padding: 8px 10px; border-radius: 12px; background: #f1e8ff; font-size: 12px; }
.composer-shell .private-controls button, .composer-actions button { border: 0; background: transparent; color: #7640a4; font-weight: 700; }
.composer-main textarea { margin: 0; }
.composer-shell .composer-main .tool-button { background: #f3edf9; color: #7043a0; }
.composer-shell .composer-main .button { background: var(--purple); color: #fff; }
.composer-shell .composer-tools button { background: transparent; color: #7640a4; }
.composer-actions { min-height: 0; text-align: right; }
.composer-actions button:disabled { display: none; }
.tool-panel { position: absolute; left: 12px; right: 12px; bottom: 112px; z-index: 8; padding: 12px; border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: var(--shadow); }
.emoji-panel button { border: 0; background: transparent; padding: 7px; font-size: 22px; }
.gif-panel form { display: flex; gap: 8px; }
.gif-results { display: grid; grid-template-columns: repeat(4,1fr); gap: 7px; max-height: 260px; overflow: auto; margin-top: 10px; }
.gif-results button { border: 0; padding: 0; background: transparent; }
.gif-results img { width: 100%; height: 84px; border-radius: 9px; object-fit: cover; }
.recording:not([hidden]) { display: grid; grid-template-columns: auto auto minmax(54px,1fr) auto auto; align-items: center; gap: 9px; }
.recording [hidden] { display: none !important; }
.recording audio { grid-column: 1 / -1; width: 100%; max-width: none; height: 42px; }
.recording small { grid-column: 1 / -1; width: 100%; }
.recording .audio-send { background: var(--purple); color: #fff; }
.recording button:disabled { opacity: .55; cursor: wait; }
@media (max-width: 720px) {
  .recording:not([hidden]) { grid-template-columns: auto minmax(50px,1fr) auto; }
  .recording strong { grid-column: span 1; }
  .recording [data-audio-cancel], .recording [data-audio-retry], .recording [data-audio-send] { grid-column: span 1; }
  .recording button { padding: 7px 8px; font-size: 11px; }
}
.report-panel { position: absolute; z-index: 12; inset: 80px 25px auto; padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: var(--shadow); }
.conversation { position: relative; }
.feedback { position: absolute; right: 18px; bottom: 116px; z-index: 9; margin: 0; color: #b62458; font-size: 12px; }
.error { color: #b62458; font-weight: 800; }
.profile-toggle { display: flex; align-items: center; gap: 8px; margin-top: 14px; font-size: 13px; }
.profile-toggle input { width: auto; }
.photo-drop input { display: none; }
.room-help summary { cursor: pointer; font-weight: 800; }
.room-help p { margin-top: 8px; }
@media (max-width: 720px) {
  .chat-header .chat-logo { min-width: 0; }
  .chat-header-actions .button.secondary { display: none; }
  .tool-panel { bottom: 132px; }
  .gif-results { grid-template-columns: repeat(3,1fr); }
}


