* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Cal Sans', sans-serif;
    background: linear-gradient(135deg, #0f0f0f 0%, #1a1a1a 100%);
    color: #ffffff;
    min-height: 100vh;
    overflow-x: hidden;
}

body.god-mode-active {
  background: linear-gradient(135deg, #1a0033 0%, #33001a 100%);
}

.luna-container { 
  position: relative;
  z-index: 1;
}

.container-125 {
    display: flex;
    min-height: 100vh;
    background: linear-gradient(135deg, #0f0f1a 0%, #1a1a2a 100%);
}

.sidebar-125 {
    width: var(--sidebar-width);
    background: rgba(255, 255, 255, 0.05);
    padding: 20px;
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    overflow-y: auto;
}

.main-content-125 {
    flex: 1;
    padding: 20px;
}

.panel-content-125 {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    height: 100%;
    overflow-y: auto;
}

.features-tabs-125 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.features-tabs-125 .tab-btn {
    /* @tweakable tab button sizing */
    padding: 12px 8px;
    font-size: 0.9rem;
    text-align: center;
}

.control-group-125 {
    margin: 15px 0;
    padding: 15px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
}

.omnipotent-btn {
    /* @tweakable special effect intensity */
    box-shadow: 0 0 calc(20px * var(--sfx-intensity)) #ff00ff;
}

.container { 
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.avatar-section {
    position: relative; /* Changed from sticky to relative for sidebar flow */
    top: auto; /* Reset top */
    margin: 0 auto 20px; /* Reset margin */
    width: auto; /* Allow it to take sidebar width */
}

.avatar-container {
    width: 260px; /* Adjust for sidebar */
    height: 340px; /* Adjust for sidebar */
    margin: 0 auto 20px; /* Center within sidebar */
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    background: linear-gradient(145deg, #2d2d2d, #1a1a1a);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s ease;
}

.avatar-container:hover {
    transform: translateY(-5px);
}

.avatar-container.speaking {
    animation: pulse 1.5s ease-in-out infinite;
}

.avatar-container.emotion-happy {
    animation: bounce 1s ease-in-out;
}

.avatar-container.emotion-excited {
    animation: shake 0.5s ease-in-out;
}

.avatar-container.emotion-sad {
    filter: brightness(0.8);
}

.avatar-container.emotion-calm {
    animation: gentle-sway 2s ease-in-out;
}

.avatar-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avatar-status {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    padding: 8px 16px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.customize-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
    border: none;
    border-radius: 10px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.customize-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(255, 107, 107, 0.3);
}

.feature-panels {
    position: relative; /* Ensure panels are positioned correctly */
    padding: 20px; /* Add some padding inside the content area */
}

.feature-panels .panel {
    display: none;
}

.feature-panels .panel.active {
    display: block;
}

.chat-container {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.ai-status {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    color: #4ecdc4;
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    animation: pulse 2s ease-in-out infinite;
}

.chat-messages {
    height: 400px;
    overflow-y: auto;
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
}

.message {
    margin-bottom: 15px;
    padding: 12px 16px;
    border-radius: 18px;
    max-width: 80%;
    word-wrap: break-word;
    animation: messageSlide 0.3s ease-out;
}

.message.user {
    background: linear-gradient(135deg, #4ecdc4, #45b7d1);
    margin-left: auto;
    text-align: right;
}

.message.ai {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.chat-input-container {
    display: flex;
    gap: 10px;
}

.chat-input-container input {
    flex: 1;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: white;
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
}

.chat-input-container input:focus {
    border-color: #4ecdc4;
    box-shadow: 0 0 0 3px rgba(78, 205, 196, 0.2);
}

.chat-input-container button {
    padding: 12px 24px;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    border: none;
    border-radius: 10px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.chat-input-container button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(78, 205, 196, 0.3);
}

.calls-container {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.calls-container h3 {
    color: #4ecdc4;
    margin-bottom: 30px;
    text-align: center;
}

.call-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.call-option {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.call-option h4 {
    color: #4ecdc4;
    margin-bottom: 10px;
}

.call-btn {
    padding: 15px 30px;
    border: none;
    border-radius: 10px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
    margin-top: 15px;
}

.voice-call-btn {
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
}

.video-call-btn {
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
}

.call-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(78, 205, 196, 0.3);
}

.call-status {
    margin: 15px 0;
    text-align: center;
}

.listening-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #4ecdc4;
    font-size: 0.9rem;
}

.pulse-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    animation: pulse 1.5s ease-in-out infinite;
}

.speaking-indicator {
    display: none;
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255, 107, 107, 0.8);
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    animation: pulse 1s ease-in-out infinite;
}

.speaking-indicator::after {
    content: "🔊 Speaking";
}

.test-btn {
    background: linear-gradient(45deg, #45b7d1, #4ecdc4);
    padding: 8px 16px;
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.test-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(69, 183, 209, 0.3);
}

.call-interface, .video-call-interface {
    background: rgba(0, 0, 0, 0.8);
    border-radius: 15px;
    padding: 20px;
    margin-top: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.call-controls {
    text-align: center;
}

.call-controls h3 {
    color: #4ecdc4;
    margin-bottom: 15px;
}

.call-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin: 20px 0;
}

.end-call-btn {
    background: linear-gradient(45deg, #ff6b6b, #ff8e8e);
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-weight: 600;
}

.mute-btn {
    background: rgba(255, 255, 255, 0.2);
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-weight: 600;
}

.video-call-container {
    display: flex;
    flex-direction: column;
    height: 500px;
}

.video-streams {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.luna-video, .user-video-container {
    flex: 1;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 10px;
    text-align: center;
}

.luna-video {
    position: relative;
}

.user-video-container {
    position: relative;
}

.user-video-container .listening-indicator {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
}

.luna-avatar-video {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 10px;
}

#user-video {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 10px;
}

.video-call-messages {
    flex: 1;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    padding: 15px;
    overflow-y: auto;
    margin-bottom: 15px;
}

.video-call-message {
    margin-bottom: 10px;
    padding: 8px 12px;
    border-radius: 15px;
    max-width: 80%;
}

.video-call-message.user {
    background: linear-gradient(135deg, #4ecdc4, #45b7d1);
    margin-left: auto;
    text-align: right;
}

.video-call-message.ai {
    background: rgba(255, 255, 255, 0.1);
}

.video-call-controls {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 10px;
}

.video-call-controls button {
    padding: 8px 16px;
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.video-btn {
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
}

.snapshot-btn {
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
}

.call-settings {
    margin-top: 30px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.call-settings h4 {
    color: #4ecdc4;
    margin-bottom: 15px;
}

.setting-group {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.setting-group label {
    min-width: 120px;
    color: #cccccc;
}

.setting-group select,
.setting-group input[type="number"],
.setting-group input[type="range"] {
    flex: 1;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: white;
    outline: none;
    transition: all 0.3s ease;
}

.setting-group input[type="range"] {
    -webkit-appearance: none;
    height: 6px;
    border-radius: 3px;
    cursor: pointer;
}

.setting-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    border-radius: 50%;
    cursor: pointer;
}

.setting-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: #4ecdc4;
    cursor: pointer;
}

.setting-group input:focus,
.setting-group select:focus {
    border-color: #4ecdc4;
    box-shadow: 0 0 0 3px rgba(78, 205, 196, 0.2);
}

.setting-group span {
    color: #4ecdc4;
    font-weight: 600;
    min-width: 30px;
    text-align: right;
}

.ai-tools-container {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.ai-tools-container h3 {
    color: #4ecdc4;
    margin-bottom: 30px;
    text-align: center;
    font-size: 2rem;
}

.ai-tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.ai-tool-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: transform 0.3s ease;
}

.ai-tool-card:hover {
    transform: translateY(-5px);
}

.ai-tool-card h4 {
    color: #4ecdc4;
    margin-bottom: 10px;
    font-size: 1.2rem;
}

.ai-tool-card p {
    color: #cccccc;
    margin-bottom: 15px;
    font-size: 0.9rem;
}

.tool-controls {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
}

.tool-controls input[type="file"] {
    padding: 8px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: white;
    font-size: 0.9rem;
    resize: vertical;
    outline: none;
}

.tool-controls textarea {
    padding: 10px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: white;
    font-size: 0.9rem;
    resize: vertical;
    min-height: 60px;
    outline: none;
}

.tool-controls button {
    padding: 10px 15px;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    border: none;
    border-radius: 6px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tool-controls button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(78, 205, 196, 0.3);
}

.tool-controls button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.advanced-controls {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 10px;
    align-items: center;
    margin: 10px 0;
}

.advanced-controls label {
    color: #cccccc;
    font-size: 0.9rem;
}

.advanced-controls select {
    padding: 6px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    color: white;
    font-size: 0.9rem;
}

.tool-output {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    padding: 15px;
    min-height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    font-style: italic;
    text-align: center;
}

.tool-output img {
    max-width: 100%;
    max-height: 300px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.tool-output.processing {
    color: #4ecdc4;
    font-weight: 600;
}

.tool-output.error {
    color: #ff6b6b;
    font-weight: 600;
}

.video-generation-controls {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 15px;
    flex-wrap: wrap;
}

.video-generation-controls button {
    padding: 10px 15px;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.video-generation-controls button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.3);
}

#generate-advanced-video-btn {
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
    border: none;
    border-radius: 10px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 12px 24px;
    font-size: 1rem;
    pointer-events: auto;
    user-select: none;
    min-width: 200px;
}

#generate-advanced-video-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(255, 107, 107, 0.3);
}

#generate-advanced-video-btn:active {
    transform: translateY(0);
    box-shadow: 0 5px 10px rgba(255, 107, 107, 0.2);
}

#generate-advanced-video-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.typing-indicator {
    opacity: 0.7;
    animation: fadeIn 0.3s ease-in;
}

.typing-dots {
    display: flex;
    gap: 4px;
    justify-content: center;
    align-items: center;
    padding: 8px;
}

.typing-dots .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #4ecdc4;
    animation: typing 1.4s infinite;
}

.typing-dots .dot:nth-child(1) { animation-delay: 0s; }
.typing-dots .dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dots .dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing {
    0%, 60%, 100% {
        transform: translateY(0);
        opacity: 0.4;
    }
    30% {
        transform: translateY(-10px);
        opacity: 1;
    }
}

.avatar-grid, .people-grid, .frames-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
    margin: 15px 0;
}

.avatar-item, .person-item, .frame-item {
    text-align: center;
    background: rgba(255, 255, 255, 0.1);
    padding: 10px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.avatar-item img, .person-item img, .frame-item img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #4ecdc4;
}

.frame-item img {
    border-radius: 8px;
    height: 60px;
    width: 100px;
}

.avatar-item p, .person-item p, .frame-item p {
    margin-top: 8px;
    color: #cccccc;
    font-size: 0.8rem;
}

.avatar-showcase, .people-showcase, .frames-showcase {
    margin: 20px 0;
    padding: 15px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
}

.avatar-showcase h5, .people-showcase h5, .frames-showcase h5 {
    color: #4ecdc4;
    margin-bottom: 15px;
    text-align: center;
}

.personality-btn.romantic, .personality-btn.seductive, .personality-btn.unrestricted {
    border: 2px solid #ff6b6b;
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.2), rgba(255, 107, 107, 0.1));
}

.personality-btn.romantic:hover, .personality-btn.seductive:hover, .personality-btn.unrestricted:hover {
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.3), rgba(255, 107, 107, 0.2));
    transform: translateY(-3px);
}

.scenario-btn.romantic_date, .scenario-btn.bedroom, .scenario-btn.adult_fantasy, .scenario-btn.anything {
    border: 2px solid #ff6b6b;
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.2), rgba(255, 107, 107, 0.1));
}

.scenario-btn.romantic_date:hover, .scenario-btn.bedroom:hover, .scenario-btn.adult_fantasy:hover, .scenario-btn.anything:hover {
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.3), rgba(255, 107, 107, 0.2));
    transform: translateY(-3px);
}

.video-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 20px;
    flex-wrap: wrap;
}

.video-actions button {
    padding: 10px 20px;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    font-weight: 600;
}

.video-actions button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(78, 205, 196, 0.3);
}

.music-elements {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.music-element {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.music-element h6 {
    color: #4ecdc4;
    margin-bottom: 8px;
}

.music-element p {
    color: #cccccc;
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.music-element audio {
    width: 100%;
}

.music-controls {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 15px;
}

.music-controls button {
    padding: 8px 16px;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.composition-details {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    padding: 15px;
    margin: 15px 0;
}

.composition-details h5 {
    color: #4ecdc4;
    margin-bottom: 10px;
}

.output-section {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    min-height: 200px;
}

.output-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #888;
    font-style: italic;
}

.generated-content {
    text-align: center;
}

.generated-content img {
    max-width: 100%;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.generated-content video {
    max-width: 100%;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.generated-content audio {
    width: 100%;
    margin-top: 10px;
}

.customization-panel {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    pointer-events: auto;
}

.customization-panel.active {
    display: flex;
}

.customization-panel * {
    pointer-events: auto;
}

.customization-content {
    background: linear-gradient(145deg, #2d2d2d, #1a1a1a);
    border-radius: 20px;
    padding: 40px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.customization-content h3 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 2rem;
    color: #4ecdc4;
}

.customization-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.customization-section h4 {
    margin-bottom: 15px;
    color: #cccccc;
    font-size: 1.1rem;
}

.customization-section h4 .override-text {
    font-size: 0.8rem;
    color: #888;
    font-weight: 400;
}

.customization-section textarea {
    width: 100%;
    min-height: 80px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: white;
    font-size: 0.9rem;
    resize: vertical;
    outline: none;
    margin-bottom: 15px;
}

.customization-section textarea:focus {
    border-color: #4ecdc4;
    box-shadow: 0 0 0 3px rgba(78, 205, 196, 0.2);
}

.customization-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.generate-avatar-btn {
    flex: 1;
    padding: 15px;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    border: none;
    border-radius: 10px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.generate-avatar-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(78, 205, 196, 0.3);
}

.option-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.option-buttons button {
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.option-buttons button:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.option-buttons button.active {
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    border-color: transparent;
}

.close-btn {
    flex: 1;
    padding: 15px;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
    border: none;
    border-radius: 10px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.close-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(255, 107, 107, 0.3);
}

#avatar-prompt-preview {
    background: rgba(0, 0, 0, 0.3);
    padding: 15px;
    border-radius: 10px;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    word-break: break-word;
}

.login-panel {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    z-index: 1500;
    display: none;
    align-items: center;
    justify-content: center;
}

.login-panel.active {
    display: flex;
}

.login-content {
    background: linear-gradient(145deg, #2d2d2d, #1a1a1a);
    border-radius: 20px;
    padding: 40px;
    max-width: 400px;
    width: 90%;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
}

.login-content h3 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 2rem;
    color: #4ecdc4;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.login-form input {
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: white;
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
}

.login-form input:focus {
    border-color: #4ecdc4;
    box-shadow: 0 0 0 3px rgba(78, 205, 196, 0.2);
}

.login-form button {
    padding: 15px;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    border: none;
    border-radius: 10px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.login-form button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(78, 205, 196, 0.3);
}

.user-info {
    text-align: center;
}

.user-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    margin: 0 auto 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
}

.account-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    background: linear-gradient(45deg, #4ecdc4, #45b7d1);
    border: none;
    border-radius: 25px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 1000;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.account-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(78, 205, 196, 0.3);
}

.account-btn.logged-in {
    background: linear-gradient(45deg, #28a745, #4ecdc4);
}

.error-content {
    text-align: center;
    padding: 20px;
    color: #ff6b6b;
}

.error-content h4 {
    color: #ff6b6b;
    margin-bottom: 15px;
}

.section-description {
    color: #a0a0a0;
    text-align: center;
    margin-bottom: 30px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.explanation-text {
    font-size: 0.85rem;
    color: #888;
    margin-top: -10px;
    margin-bottom: 10px;
    text-align: center;
}

/* @tweakable Controls interactivity for disabled elements */
button:disabled,
input:disabled,
textarea:disabled,
select:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* @tweakable Ensures all non-disabled buttons are clickable */
button:not([disabled]) {
    cursor: pointer !important;
    pointer-events: auto !important;
    transition: transform 0.1s ease, background-color 0.2s ease;
}

/* @tweakable Ensures tab buttons are always clickable unless explicitly disabled */
.tab-btn:not([disabled]) {
    cursor: pointer !important;
    pointer-events: auto !important;
}

/* @tweakable Ensures personality and scenario buttons are clickable */
.personality-btn:not([disabled]),
.scenario-btn:not([disabled]) {
    cursor: pointer !important;
    pointer-events: auto !important;
}

/* @tweakable Ensures customization option buttons are clickable */
.option-buttons button:not([disabled]) {
    cursor: pointer !important;
    pointer-events: auto !important;
}

/* @tweakable loading overlay adjustments */
.loading-overlay {
    /* Allows interacting with elements underneath */
    pointer-events: none !important;
    background: rgba(0,0,0,0.65); /* Improved visibility */
    backdrop-filter: blur(10px);
  
    /* Prevent the overlay from blocking pointer events */
    pointer-events: none;
}

.loading-overlay > * {
    pointer-events: none !important;
}

.tab-btn {
  cursor: pointer;
  transition: all 0.3s ease;
}

.tab-btn:hover {
  transform: translateY(-5px) scale(1.05);
}

.divine-glow {
  box-shadow: 0 0 40px #ff00ff, 0 0 80px #ffff00 !important;
  animation: divine-pulse 2s infinite alternate;
}

@keyframes divine-pulse {
  0% { transform: scale(1); }
  100% { transform: scale(1.05); }
}

.btn-active {
  transform: scale(0.95);
  opacity: 0.9;
}

.btn-error {
  animation: shake 0.5s ease 2;
  outline: 2px solid #ff6b6b !important;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-3px); }
  40%, 80% { transform: translateX(3px); }
}

.content-wrapper {
  pointer-events: auto !important;
}

.customization-panel {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: rgba(0,0,0,0.7);
  padding: 15px;
  border-radius: 10px;
  z-index: 1000;
  
  /* Ensure it can be interacted with */
  pointer-events: auto;
}

.customization-panel * {
  pointer-events: auto;
}

.error-display {
  position: fixed;
  top: 60px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(255, 50, 50, 0.9);
  color: white;
  padding: 12px 24px;
  border-radius: 30px;
  z-index: 10000;
  max-width: 80%;
  text-align: center;
  box-shadow: 0 4px 20px rgba(255,0,0,0.3);
}

button:disabled {
  opacity: 0.7 !important;
  cursor: wait !important;
}

button:disabled {
  cursor: not-allowed !important;
}

 Ensure clickable states 
.tab-btn,
.customize-btn,
.personality-btn,
.scenario-btn,
.creation-btn {
  pointer-events: auto;
  z-index: 10;
}

 Unresponsive buttons visual indicators 
button:disabled {
  pointer-events: none;
  opacity: 0.6;
  cursor: not-allowed;
}

 Disable overlapping elements 
.avatar-container, 
.generation-container, 
.customization-panel {
  position: relative;
  z-index: 5;
}

.tweak-panel {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: rgba(0,0,0,0.7);
  padding: 15px;
  border-radius: 10px;
  z-index: 1000;
}

.tweak-panel label {
  display: block;
  margin: 10px 0;
  color: #fff;
}

 Custom vars for tweaks 
:root {
    --sidebar-width: 300px;
    --sfx-intensity: 1;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes messageSlide {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.1);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-3px); }
    40%, 80% { transform: translateX(3px); }
}

@keyframes gentle-sway {
    0%, 100% { transform: rotate(0deg); }
    50% { transform: rotate(1deg); }
}