/* --- Tokyo Ghoul RP UI --- */
/* --- Theme: Ghoul Red & Black --- */
tg {
    --bg: #100c0c;
    --text: #c9c9c9;
    --primary: #e53935; /* Blood Red */
    --secondary: rgba(30, 20, 20, 0.5); /* Panel BG */
    --border: rgba(229, 57, 53, 0.3);
    --glow: 0 0 12px rgba(229, 57, 53, 0.8);
    --font-main: 'Noto Sans SC', sans-serif;
    --font-head: 'Oswald', sans-serif;

    display: block;
    background-color: var(--bg);
    /* A subtle spider lily background pattern */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='40' viewBox='0 0 100 100'%3E%3Cpath d='M50 0 C55 20 70 25 75 40 S65 65 50 70 C35 65 25 55 25 40 S45 20 50 0' fill='none' stroke='rgba(229, 57, 53, 0.08)' stroke-width='2'/%3E%3Cpath d='M50 100 C55 80 70 75 75 60 S65 35 50 30 C35 35 25 45 25 60 S45 80 50 100' fill='none' stroke='rgba(229, 57, 53, 0.08)' stroke-width='2'/%3E%3C/svg%3E");
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text);
    padding: 12px;
    font-family: var(--font-main);
    font-size: 16px;
    line-height: 1.6;
    margin: -10px; /* Counteract default chat bubble margin */
}

/* --- Header --- */
tg hd {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 5px 15px;
    padding: 5px 8px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 15px;
    font-size: 13px;
    color: #a0a0a0;
}
tg hd t:first-child {
    font-weight: bold;
    color: var(--text);
}

/* --- Article/Narrative --- */
tg article {
    margin-bottom: 20px;
}
tg article p {
    margin: 0 0 1em 0;
    padding: 0;
}
tg article p:last-child {
    margin-bottom: 0;
}

/* --- Details Panel --- */
tg details {
    border: 1px solid var(--border);
    border-radius: 6px;
    transition: all 0.3s ease-in-out;
}
tg details[open] {
    box-shadow: var(--glow);
    border-color: var(--primary);
}
tg details summary {
    font-family: var(--font-head);
    padding: 10px 15px;
    background-color: rgba(0, 0, 0, 0.2);
    cursor: pointer;
    font-size: 1.2em;
    letter-spacing: 5px;
    text-align: center;
    color: var(--primary);
    text-shadow: var(--glow);
    list-style: none; /* Remove marker for Safari/Chrome */
    outline: none;
    position: relative;
    user-select: none;
}
tg details summary::-webkit-details-marker {
    display: none; /* Hide default arrow */
}
tg details summary::before,
tg details summary::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 20px;
    width: 12px;
    height: 2px;
    background: var(--primary);
    transition: transform 0.3s ease;
}
tg details summary::after {
    transform: rotate(90deg);
}
tg details[open] summary::after {
    transform: rotate(0deg);
}

/* --- Info Grid --- */
tg .grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding: 15px;
    background: rgba(0,0,0,0.2);
}
/* Mobile Responsive: Stacks the grid into a single column */
@media (max-width: 600px) {
    tg .grid {
        grid-template-columns: 1fr;
    }
}
tg .grid p {
    background: var(--secondary);
    border-radius: 4px;
    padding: 10px 12px;
    margin: 0;
    border-left: 3px solid var(--border);
    display: flex;
    flex-direction: column;
    transition: all 0.2s ease;
}
tg .grid p:hover {
    border-left-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

/* --- Partition Title & Data --- */
tg f {
    display: block;
    font-family: var(--font-head);
    font-weight: bold;
    color: var(--text);
    margin-bottom: 8px;
    padding-bottom: 5px;
    border-bottom: 1px solid var(--border);
    font-size: 1.1em;
}
/* Style titles based on status */
tg f[st="喰种"], tg f[st="羽赫"], tg f[st="甲赫"],tg f[st="混合赫（奇美拉）"]， tg f[st="鳞赫"], tg f[st="尾赫"] {
    color: var(--primary);
}
tg f[st="ccg"] {
    color: #1e88e5; /* A hint of CCG blue */
}

tg d {
    display: block;
    font-size: 14px;
    margin-bottom: 4px;
    line-height: 1.5;
}
tg d b {
    color: #b8b8b8;
    font-weight: normal;
}

/* --- Action Options --- */
tg .actions {
    padding: 15px;
    background: rgba(0,0,0,0.3);
    border-top: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 8px;
}
tg q {
    display: block;
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    font-size: 15px;
}
tg q:hover {
    background: var(--primary);
    color: var(--bg);
    border-color: var(--primary);
    text-shadow: none;
    box-shadow: var(--glow);
    transform: translateX(5px);
}
