/* ---------- HEADER STYLING ---------- */
.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
}

.header-middle-title { flex: 1; text-align: center; }
.header-center { font-size: 2em; margin: 0 0 20px 0; }

/* ---------- PANEL LAYOUT ---------- */
.content-container {
    display: flex;
    height: 100%;
    width: 100%;
    justify-content: center;
    align-items: stretch;
    overflow-y: auto;
}

.game-mode-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    position: relative;
    margin: auto;
    overflow: auto;
    height: 100%;
}

#quick-guide-panel {
    justify-content: center;
}

/* Divider lines between panels */
.game-mode-panel::before,
.game-mode-panel::after {
    content: "";
    position: absolute;
    top: 10%;
    bottom: 10%;
    width: 1px;
    background: linear-gradient(to bottom, rgba(0,0,0,0.05), rgba(0,0,0,0.3), rgba(0,0,0,0.05));
}
.game-mode-panel::before { left: 0; }
.game-mode-panel::after { right: 0; }

.panel-content { width: 100%; max-width: 350px; margin: 0 auto; }

/* ---------- TYPOGRAPHY ---------- */
h1 { margin: 0 0 20px 0; font-size: 2rem; text-align: center; }
h2 { margin: 15px 0; font-size: 1.5rem; text-align: center; }
h3 { margin: 10px 0; font-size: 1.2rem; }

/* ---------- GUIDE LIST STYLING ---------- */
.guide-list { list-style-type: disc; padding-left: 20px; margin-bottom: 20px; }
.guide-list li { margin-bottom: 10px; line-height: 1.4; }
.end-text { color: green; font-weight: bold; }
.game-over-text { color: red; font-weight: bold; }

/* ---------- CHARACTER STYLING ---------- */
.character-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 20px;
}

.character-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 10px;
    border-bottom: 1px solid #eee;
}

.character-image { width: 60px; height: 60px; object-fit: contain; }
.character-info { flex: 1; }
.character-info p { margin: 5px 0; line-height: 1.4; }

/* Character Stats Styling */
.character-stats {
    margin-top: 10px;
    font-size: 0.9rem;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 5px;
}

.stat-item { display: flex; align-items: center; }
.stat-label { font-weight: bold; margin-right: 5px; color: #555; }
.stat-value { color: #007bff; }
.special-ability { grid-column: span 2; margin-top: 5px; font-style: italic; color: #28a745; }
.special-capability { grid-column: span 2; margin-top: 5px; font-style: italic; color: #6c5ce7; }
.ascension-ability {
    grid-column: span 2;
    margin-top: 4px;
    font-style: italic;
    color: #d4af37; /* gold */
}
.threat-level { color: red; font-weight: bold; }

/* Last Updated Datestamp Styling */
.last-updated-container {
    text-align: center;
    margin: 20px 0 10px;
    font-size: 0.9rem;
    color: #666;
}

.last-updated-text {
    margin: 0;
    padding: 0;
}

.last-updated-date {
    color: cornflowerblue;
    font-weight: bold;
}

/* ---------- PANEL TOGGLE ---------- */
.panel-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 15px 0;
    width: 100%;
}

.toggle-btn {
    background: transparent;
    border: none;
    color: rgba(0,0,0,0.5);
    font-weight: 700;
    cursor: pointer;
    padding: 6px 10px;
    font-size: 1.05em;
}
.toggle-btn.active { color: #003747; }
.toggle-btn:disabled { opacity: .6; cursor: not-allowed; }

.toggle-divider {
    width: 1px; height: 18px;
    background: linear-gradient(to bottom, rgba(0,0,0,0), rgba(0,0,0,0.25), rgba(0,0,0,0));
    transform: skew(-15deg);
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 768px) {
    #main { width: 300px; }
    .content-container { flex-direction: column; justify-content: normal; overflow: auto;}
    .game-mode-panel { margin: 10px 0; overflow: visible; height: auto; flex: 0 0 auto; }
    /* Hide vertical divider lines when stacked */
    .game-mode-panel::before, .game-mode-panel::after { display: none; content: none; }
    .panel-content { max-width: 100%; }
    .character-item { flex-direction: column; align-items: center; text-align: center; }
    .character-image { width: 80px; height: 80px; }
    #quick-guide-panel {justify-content: normal;}
}

@media (max-height: 1000px){
    #main { width: 100%; }
    #quick-guide-panel {justify-content: normal;}
}