:root{--bezel:#11151c;--stage:#e9edf4;--wa-header:#075e54;--wa-bg:#efe7dd;--wa-mine:#d9fdd3;--wa-accent:#00a884;--rcs-accent:#0b57d0;--rcs-mine:#d3e3fd;--rcs-theirs:#f0f4f9;--sms-mine:#34c759;--text:#111b21;--muted:#667781}
[hidden]{display:none!important}*{box-sizing:border-box}html,body{margin:0;height:100%}body{background:var(--stage);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;color:var(--text)}button,input{font:inherit}
.stage{min-height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:14px;padding:24px 16px}
.phone{position:relative;width:390px;height:800px;max-height:calc(100vh - 80px);min-height:560px;border-radius:52px;border:12px solid var(--bezel);background:#fff;display:flex;flex-direction:column;overflow:hidden;box-shadow:0 30px 80px #1a2b5a33}
.statusbar{height:44px;flex:0 0 44px;display:flex;align-items:center;justify-content:space-between;padding:0 26px;font-size:14px;font-weight:600;color:#fff;background:var(--wa-header);position:relative}
.notch{position:absolute;left:50%;top:8px;transform:translateX(-50%);width:118px;height:30px;border-radius:20px;background:var(--bezel)}
.status-icons{display:flex;gap:3px;align-items:flex-end}.status-icons i{display:block;width:3px;background:currentColor;border-radius:1px}.status-icons i:nth-child(1){height:5px}.status-icons i:nth-child(2){height:8px}.status-icons i:nth-child(3){height:11px}.status-icons b{display:block;width:22px;height:11px;border:1.5px solid currentColor;border-radius:3px;margin-left:5px;background:linear-gradient(90deg,currentColor 70%,transparent 70%)}
.notification{position:absolute;z-index:5;top:52px;left:10px;right:10px;background:#f7f7f8f2;backdrop-filter:blur(12px);border-radius:18px;padding:11px 14px;box-shadow:0 8px 30px #0003;display:flex;flex-direction:column;gap:3px;font-size:13px;color:#111;animation:drop .35s ease-out}.notification-app{font-size:11px;color:#666}.mail-icon{display:inline-grid;place-items:center;width:18px;height:18px;border-radius:5px;background:#1a73e8;color:#fff;font-size:11px;margin-right:4px}.notification span:last-child{color:#333;line-height:1.35;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}@keyframes drop{from{transform:translateY(-30px);opacity:0}}
.app-header{display:flex;align-items:center;gap:10px;padding:8px 12px 10px;background:var(--wa-header);color:#fff;flex:0 0 auto}.back{font-size:30px;line-height:1;margin-right:-2px}.avatar{width:38px;height:38px;border-radius:50%;display:grid;place-items:center;font-weight:700;background:linear-gradient(135deg,#0f5fdc,#5f1ebe);color:#fff}.who{display:flex;flex-direction:column;min-width:0}.who strong{font-size:16px}.who small{font-size:12px;opacity:.85}.verified{display:inline-grid;place-items:center;width:15px;height:15px;border-radius:50%;background:#25d366;color:#fff;font-size:9px;vertical-align:1px;margin-left:3px}
.thread{flex:1;overflow-y:auto;padding:12px 10px 14px;display:flex;flex-direction:column;gap:6px;background:var(--wa-bg)}
.empty{margin:auto;color:var(--muted);font-size:13px}.day{align-self:center;background:#ffffffd9;color:var(--muted);font-size:11px;padding:4px 10px;border-radius:8px;margin:6px 0}
.msg{display:flex;flex-direction:column;max-width:82%}.msg.mine{align-self:flex-end;align-items:flex-end}.msg.theirs{align-self:flex-start}
.bubble{position:relative;padding:7px 10px 18px;border-radius:10px;font-size:14.5px;line-height:1.38;white-space:pre-line;overflow-wrap:anywhere;box-shadow:0 1px .5px #0b141a21;background:#fff;min-width:88px}.mine .bubble{background:var(--wa-mine)}
.meta{position:absolute;right:8px;bottom:3px;font-size:11px;color:var(--muted);display:flex;gap:4px}.ticks{color:#53bdeb;letter-spacing:-3px}.via{display:block;font-size:10px;font-weight:700;letter-spacing:.4px;text-transform:uppercase;color:var(--muted);margin-bottom:2px}
.bubble-buttons{display:flex;flex-direction:column;gap:2px;margin-top:2px;width:100%}.bubble-buttons button{background:#fff;border:0;border-radius:8px;padding:9px;color:var(--wa-accent);font-weight:600;font-size:14px;cursor:pointer;box-shadow:0 1px .5px #0b141a21}.bubble-buttons button:disabled{color:#9aa5ab;cursor:default}
.typing{display:flex;align-items:center;gap:4px;padding:10px 14px;min-width:0}.typing-label{font-size:13px;color:var(--muted);margin-right:4px}.ticks.sending{color:var(--muted)}.typing i{width:7px;height:7px;border-radius:50%;background:#9aa5ab;animation:blink 1.2s infinite}.typing i:nth-child(2){animation-delay:.2s}.typing i:nth-child(3){animation-delay:.4s}@keyframes blink{50%{opacity:.25}}
.chips{display:flex;gap:8px;overflow-x:auto;padding:0 10px;background:var(--wa-bg)}.chips:not(:empty){padding:8px 10px}.chips button{flex:0 0 auto;border:1px solid var(--rcs-accent);color:var(--rcs-accent);background:#fff;border-radius:18px;padding:8px 14px;font-size:14px;cursor:pointer}
.composer{display:flex;gap:8px;padding:8px 10px 6px;background:var(--wa-bg)}.composer input{flex:1;border:0;border-radius:22px;padding:11px 16px;font-size:15px;background:#fff;outline:0;min-width:0}.composer button{width:44px;height:44px;border-radius:50%;border:0;background:var(--wa-accent);color:#fff;font-size:17px;cursor:pointer}
.home-indicator{height:22px;flex:0 0 22px;background:var(--wa-bg);position:relative}.home-indicator::after{content:'';position:absolute;left:50%;top:8px;transform:translateX(-50%);width:130px;height:5px;border-radius:3px;background:#111}
.caption{margin:0;font-size:12px;color:#5d6b85}
/* RCS: Google Messages look */
[data-app=RCS] .statusbar{background:#fff;color:#1f1f1f}[data-app=RCS] .app-header{background:#fff;color:#1f1f1f;border-bottom:1px solid #e3e3e3}[data-app=RCS] .verified{background:var(--rcs-accent)}
[data-app=RCS] .thread,[data-app=RCS] .chips,[data-app=RCS] .composer,[data-app=RCS] .home-indicator{background:#fff}[data-app=RCS] .bubble{background:var(--rcs-theirs);box-shadow:none;border-radius:18px;padding:10px 14px 20px}[data-app=RCS] .mine .bubble{background:var(--rcs-mine)}
[data-app=RCS] .bubble-buttons button{background:#fff;color:var(--rcs-accent);border:1px solid #c4c7c5;border-radius:18px;box-shadow:none}[data-app=RCS] .ticks{color:var(--muted);letter-spacing:0}[data-app=RCS] .composer input{background:#f0f4f9}[data-app=RCS] .composer button{background:var(--rcs-accent)}[data-app=RCS] .day{background:transparent}
/* SMS: plain messages app */
[data-app=SMS] .statusbar{background:#f6f6f6;color:#111}[data-app=SMS] .app-header{background:#f6f6f6;color:#111;border-bottom:1px solid #ddd}[data-app=SMS] .verified{display:none}[data-app=SMS] .thread,[data-app=SMS] .chips,[data-app=SMS] .composer,[data-app=SMS] .home-indicator{background:#fff}[data-app=SMS] .bubble{background:#e9e9eb;border-radius:18px;box-shadow:none}[data-app=SMS] .mine .bubble{background:var(--sms-mine);color:#fff}[data-app=SMS] .mine .meta,[data-app=SMS] .mine .ticks{color:#ffffffcc}[data-app=SMS] .composer button{background:var(--sms-mine)}[data-app=SMS] .composer input{border:1px solid #ddd}
@media(max-width:480px){.stage{padding:0;gap:0}.phone{width:100%;height:100vh;max-height:none;border:0;border-radius:0}.caption,.notch{display:none}}
