/* Solo2 Component: Chat Panel Texture
   Voronoi mesh — irregular cellular pattern (P2P decentralization metaphor)
   Computed via Bowyer-Watson Delaunay → circumcenter Voronoi, 15 jittered seeds
   300x300px tile, seamless tiling (boundary crossings match on opposite edges)
   Asymmetric by nature: no visible grid repetition */

.panel-chat {
    position: relative;
}

/* Depth gradient: darker edges draw eye to center (messages) */
.panel-chat::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    background: radial-gradient(ellipse at center, transparent 30%, rgba(0,0,0,0.18) 100%);
}

[data-theme="light"] .panel-chat::before {
    background: radial-gradient(ellipse at center, transparent 40%, rgba(0,0,0,0.06) 100%);
}

/* Voronoi mesh — 300x300px seamless tile, 54 edges, 15 cells */
.panel-chat::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    opacity: 0.35;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300' viewBox='0 0 300 300'%3E%3Cpath d='M68.4,0.0L69.0,8.2M123.0,0.0L122.3,5.8M0.0,183.4L14.2,182.2M0.0,1.3L56.1,16.3M0.0,93.4L1.2,94.1M69.0,8.2L122.3,5.8M69.0,8.2L56.1,16.3M56.1,16.3L58.2,80.1M122.3,5.8L123.7,7.2M123.7,7.2L174.5,14.6M123.7,7.2L121.5,97.4M192.6,0.0L174.5,14.6M174.5,14.6L197.7,98.3M235.6,0.0L229.7,90.7M297.4,0.0L297.9,0.7M14.2,182.2L1.2,94.1M14.2,182.2L33.6,192.3M1.2,94.1L58.2,80.1M58.2,80.1L81.5,96.2M81.5,96.2L118.7,99.1M81.5,96.2L33.6,192.3M33.6,192.3L40.3,199.9M197.7,98.3L208.3,103.9M197.7,98.3L121.5,97.4M121.5,97.4L118.7,99.1M118.7,99.1L117.7,205.1M229.7,90.7L280.9,82.0M229.7,90.7L208.3,103.9M208.3,103.9L208.7,106.9M208.7,106.9L175.3,190.6M208.7,106.9L273.8,185.5M40.3,199.9L61.7,207.0M40.3,199.9L0.0,276.9M117.7,205.1L132.9,213.1M117.7,205.1L61.7,207.0M61.7,207.0L68.4,300.0M132.9,213.1L134.9,212.9M132.9,213.1L123.0,300.0M175.3,190.6L241.3,215.6M175.3,190.6L134.9,212.9M134.9,212.9L213.8,282.9M273.8,185.5L300.0,183.4M273.8,185.5L241.3,215.6M241.3,215.6L238.9,279.3M297.9,0.7L300.0,1.3M297.9,0.7L280.9,82.0M280.9,82.0L300.0,93.4M300.0,276.9L291.8,292.6M213.8,282.9L236.9,280.5M213.8,282.9L192.6,300.0M238.9,279.3L291.8,292.6M238.9,279.3L236.9,280.5M236.9,280.5L235.6,300.0M291.8,292.6L297.4,300.0' fill='none' stroke='%23ffffff' stroke-width='0.5'/%3E%3C/svg%3E");
    background-size: 200px 200px;
}

/* Light theme: dark strokes, less opacity */
[data-theme="light"] .panel-chat::after {
    opacity: 0.15;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300' viewBox='0 0 300 300'%3E%3Cpath d='M68.4,0.0L69.0,8.2M123.0,0.0L122.3,5.8M0.0,183.4L14.2,182.2M0.0,1.3L56.1,16.3M0.0,93.4L1.2,94.1M69.0,8.2L122.3,5.8M69.0,8.2L56.1,16.3M56.1,16.3L58.2,80.1M122.3,5.8L123.7,7.2M123.7,7.2L174.5,14.6M123.7,7.2L121.5,97.4M192.6,0.0L174.5,14.6M174.5,14.6L197.7,98.3M235.6,0.0L229.7,90.7M297.4,0.0L297.9,0.7M14.2,182.2L1.2,94.1M14.2,182.2L33.6,192.3M1.2,94.1L58.2,80.1M58.2,80.1L81.5,96.2M81.5,96.2L118.7,99.1M81.5,96.2L33.6,192.3M33.6,192.3L40.3,199.9M197.7,98.3L208.3,103.9M197.7,98.3L121.5,97.4M121.5,97.4L118.7,99.1M118.7,99.1L117.7,205.1M229.7,90.7L280.9,82.0M229.7,90.7L208.3,103.9M208.3,103.9L208.7,106.9M208.7,106.9L175.3,190.6M208.7,106.9L273.8,185.5M40.3,199.9L61.7,207.0M40.3,199.9L0.0,276.9M117.7,205.1L132.9,213.1M117.7,205.1L61.7,207.0M61.7,207.0L68.4,300.0M132.9,213.1L134.9,212.9M132.9,213.1L123.0,300.0M175.3,190.6L241.3,215.6M175.3,190.6L134.9,212.9M134.9,212.9L213.8,282.9M273.8,185.5L300.0,183.4M273.8,185.5L241.3,215.6M241.3,215.6L238.9,279.3M297.9,0.7L300.0,1.3M297.9,0.7L280.9,82.0M280.9,82.0L300.0,93.4M300.0,276.9L291.8,292.6M213.8,282.9L236.9,280.5M213.8,282.9L192.6,300.0M238.9,279.3L291.8,292.6M238.9,279.3L236.9,280.5M236.9,280.5L235.6,300.0M291.8,292.6L297.4,300.0' fill='none' stroke='%23000000' stroke-width='0.5'/%3E%3C/svg%3E");
}

/* Ensure chat content stays above texture */
.panel-chat > * {
    position: relative;
    z-index: 1;
}
