body {
    margin: 0;
    padding: 0;
    /* Halloween Purple/Black gradient */
    background: radial-gradient(circle at center, #1a0b2e 0%, #000000 100%);
    color: #d8b4e2; /* Pale purple text */
    font-family: 'JetBrains Mono', 'Courier New', Courier, monospace;
    font-size: 13px;
    height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Halloween Hazard Warning Banner */
.warning-banner {
    background: repeating-linear-gradient(
        45deg,
        #ff6600,
        #ff6600 10px,
        #000000 10px,
        #000000 20px
    );
    color: #fff;
    text-align: center;
    padding: 8px;
    font-weight: 700;
    font-size: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
    box-shadow: 0 0 15px rgba(255, 102, 0, 0.6);
    z-index: 10;
    text-shadow: 1px 1px 2px #000;
    border-bottom: 2px solid #ff6600;
}
.blink { animation: blinker 1s linear infinite; }
@keyframes blinker { 50% { opacity: 0; } }

/* Main Layout */
.layout {
    display: flex;
    flex-grow: 1;
    overflow: hidden;
    /* Subtle spooky spiderweb/vignette overlay effect */
    box-shadow: inset 0 0 150px rgba(0,0,0,0.9);
}

/* Sidebar */
.sidebar {
    width: 300px;
    border-right: 1px solid #3d1c5d;
    padding: 20px;
    background-color: rgba(5, 0, 10, 0.95);
    display: flex;
    flex-direction: column;
    gap: 25px;
    box-shadow: inset -10px 0 20px rgba(0,0,0,0.8);
}

.sidebar-logo {
    text-align: center;
    margin-bottom: -10px;
}

.ascii-pumpkin {
    color: #ff6600;
    font-size: 12px;
    line-height: 1.1;
    font-weight: bold;
    text-shadow: 0 0 10px rgba(255, 102, 0, 0.5);
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

.sidebar-block {
    display: flex;
    flex-direction: column;
}

.sidebar-title {
    color: #ff6600;
    font-weight: 700;
    margin-bottom: 15px;
    border-bottom: 1px dashed #3d1c5d;
    padding-bottom: 5px;
    font-size: 12px;
    letter-spacing: 1px;
    text-shadow: 0 0 5px rgba(255, 102, 0, 0.3);
}

/* Vitals */
.vital-row {
    margin-bottom: 5px;
    color: #8b5cf6;
    display: flex;
    justify-content: space-between;
}
.vital-row span {
    color: #d8b4e2;
    font-weight: 700;
}

/* Rituals */
.ritual-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.ritual-list li {
    margin-bottom: 8px;
    cursor: pointer;
    color: #6b21a8;
    transition: color 0.2s;
}

.ritual-list li:hover { color: #d8b4e2; }

.ritual-list li.active {
    color: #ff6600;
    font-weight: 700;
    text-shadow: 0 0 5px rgba(255, 102, 0, 0.5);
}

.ritual-list li.active::before { content: "> "; }
.ritual-list li.locked { color: #2e1065; cursor: not-allowed; }

/* Mini Log */
#mini-log {
    font-size: 11px;
    color: #8b5cf6;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

/* Main Content */
.main-content {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    padding: 20px 40px;
    background-color: transparent;
}

.chat-header {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid #3d1c5d;
    padding-bottom: 10px;
    margin-bottom: 20px;
    font-size: 11px;
    letter-spacing: 1px;
}
.header-left .label, .header-right .label { color: #8b5cf6; }
.header-left .val { color: #d8b4e2; }

#chat-log {
    flex-grow: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding-right: 15px;
    scroll-behavior: smooth;
}
#chat-log::-webkit-scrollbar { width: 4px; }
#chat-log::-webkit-scrollbar-thumb { background-color: #ff6600; }
#chat-log::-webkit-scrollbar-track { background-color: transparent; }

.message {
    line-height: 1.6;
    word-wrap: break-word;
    white-space: pre-wrap;
    max-width: 100%;
}

.message.system {
    color: #8b5cf6;
    font-style: italic;
    border-left: 2px solid #3d1c5d;
    padding-left: 10px;
}

.message.user {
    color: #d8b4e2;
}
.message.user::before {
    content: "mortal@pump.kin:~$ ";
    color: #6b21a8;
    font-weight: 700;
}

.message.oracle {
    color: #fff; 
    border-left: 2px solid #ff6600;
    padding-left: 10px;
    background: linear-gradient(90deg, rgba(255, 102, 0, 0.08) 0%, transparent 100%);
}
.message.oracle::before {
    content: "ORACLE RESPONSE: \A";
    white-space: pre-wrap;
    color: #ff6600;
    font-weight: 700;
    text-shadow: 0 0 5px rgba(255, 102, 0, 0.8);
}

.ascii-art {
    color: #ff6600;
    display: block;
    margin-top: 15px;
    font-size: 12px;
    line-height: 1.1;
    text-shadow: 0 0 5px rgba(255, 102, 0, 0.4);
}

/* Input Area */
.input-area {
    display: flex;
    align-items: center;
    border-top: 1px solid #3d1c5d;
    padding-top: 20px;
    margin-top: 15px;
    position: relative;
}

.prompt-arrow {
    color: #6b21a8;
    margin-right: 15px;
    font-weight: 700;
}

#chat-input {
    background: transparent;
    border: none;
    color: #fff;
    font-family: inherit;
    font-size: 14px;
    flex-grow: 1;
    outline: none;
}
#chat-input::placeholder { color: #4c1d95; }

.media-container {
    margin-top: 15px;
    max-width: 350px;
    border: 1px solid #ff6600;
    padding: 5px;
    background: #000;
}
.media-container img, .media-container video { width: 100%; display: block; filter: sepia(100%) hue-rotate(330deg) saturate(300%) contrast(150%); }
