/* VARIABLES & THEME */
:root {
    /* Backgrounds & Base Colors */
    --bg-main: #2a231f; /* Deep aged wood/leather tone */
    --text-main: #e8e0d2; /* Creamy off-white (Parchment tone) */
    --pane-bg: #3d352e; /* Muted brown for container separation */
    --control-bg: #1d1612; /* Near black, deep shadow effect */
    --input-bg: #251e18; /* Very dark interior background for inputs */

    /* Accent Colors */
    --accent-gold: #d4af37; /* Rich, faded gold */
    --accent-brown: #6b4e3c; /* Dark wood brown */
    --accent-success: #a8b893; /* Muted Sage Green (Nature/Magic) */
    --accent-error: #b84d4d; /* Deep Burgundy/Maroon (Danger/Blood) */
    --accent-warning: #c6a74f; /* Dull Ochre Yellow (Warning/Doubt) */
}

body {
    font-family: Georgia, "Times New Roman", serif; /* Classic Serif Font */
    margin: 0;
    padding: 0;
    background-color: var(--bg-main);
    color: var(--text-main);
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%" viewBox="0 0 100 100" opacity=".1"><circle cx="50" cy="50" r="1" fill="#000"/></svg>');
    background-attachment: fixed;
}
.container {
    display: grid;
    gap: 20px;
    grid-template-columns: 2fr 1.2fr 1.2fr;
    grid-template-areas: "story char action";
}
.pane {
    padding: 15px;
    border-radius: 8px;
    background-color: var(--pane-bg);
    border: 1px solid #4c3e30;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}
#story-pane {
    grid-area: story;
}
#char-pane {
    grid-area: char;
}
#action-pane {
    grid-area: action;
}
#control-panel {
    padding: 20px;
    background-color: var(--control-bg);
    border-bottom: 3px solid var(--accent-gold);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
}
.control-group button {
    margin-right: 10px;
    text-transform: uppercase;
    font-weight: bold;
}
textarea,
input[type="text"] {
    width: 98%;
    padding: 10px;
    border-radius: 4px;
    border: 1px solid #5c4e42;
    background-color: var(--input-bg);
    color: var(--text-main);
    resize: none;
    font-family: Georgia, "Times New Roman", serif;
}
h3 {
    font-family: "Georgia", serif;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
    /* Applied Gold Color to all major section headings */
    color: var(--accent-gold) !important;
}

/* --- Summary Context Display Style (UPDATED) --- */
.summary-display {
    padding: 15px;
    background-color: #302a24;
    border: 1px dashed var(--accent-warning);
    border-radius: 4px;
    margin-top: 25px;
}
.summary-display h4 {
    font-size: 1.2em;
    margin-top: 0;
}
#summary_content_placeholder {
    white-space: pre-wrap;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 0.95em; /* Adjusted size */
    min-height: 150px; /* Ensure it doesn't collapse when empty */
}
