@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;600;700&display=swap');

:root {
    /* Light Mode */
    --bg-color: #f4f4f4;
    --container-bg: #ffffff;
    --text-color: #1a1a1a;
    --accent-color: #2c3e50;
    --machine-color: #2980b9;
    --user-color: #d35400;
    --border-color: #ddd;
    --code-bg: #f0f0f0;
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
    
    /* Giscus Light Variables (Matches your theme) */
    --giscus-bg: #ffffff;
    --giscus-text: #1a1a1a;
    --giscus-border: #ddd;
}

[data-theme="dark"] {
    /* Dark Mode (Nearly Black) */
    --bg-color: #0a0a0a;
    --container-bg: #111111;
    --text-color: #e0e0e0;
    --accent-color: #a0a0a0;
    --machine-color: #5dade2;
    --user-color: #e67e22;
    --border-color: #333333;
    --code-bg: #1a1a1a;
    --shadow: 0 2px 10px rgba(0,0,0,0.5);

    /* Giscus Dark Variables */
    --giscus-bg: #111111;
    --giscus-text: #e0e0e0;
    --giscus-border: #333333;
}

body {
    font-family: 'IBM Plex Mono', monospace;
    line-height: 1.6;
    color: var(--text-color);
    background: var(--bg-color);
    margin: 0;
    padding: 20px;
    transition: background 0.3s, color 0.3s;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background: var(--container-bg);
    padding: 40px;
    box-shadow: var(--shadow);
    border-radius: 4px;
    transition: background 0.3s;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
}

h1 {
    font-size: 1.8rem;
    color: var(--accent-color);
    margin: 0;
    border: none;
    padding: 0;
}

.theme-switch {
    background: none;
    border: 1px solid var(--text-color);
    color: var(--text-color);
    padding: 5px 10px;
    cursor: pointer;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.8rem;
    border-radius: 2px;
}

.theme-switch:hover {
    background: var(--text-color);
    color: var(--bg-color);
}

h2, h3 {
    color: var(--accent-color);
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
    margin-top: 40px;
}

h2 { font-size: 1.4rem; }
h3 { font-size: 1.1rem; }

.dialogue-block {
    margin-bottom: 25px;
    padding: 15px;
    border-left: 3px solid transparent;
    background: var(--code-bg);
}

.user-turn { border-left-color: var(--user-color); }
.machine-turn { border-left-color: var(--machine-color); }

.speaker {
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.75rem;
    margin-bottom: 8px;
    display: block;
    letter-spacing: 1px;
}

.user-turn .speaker { color: var(--user-color); }
.machine-turn .speaker { color: var(--machine-color); }

hr {
    border: 0;
    height: 1px;
    background: var(--border-color);
    margin: 40px 0;
}

#comments-section {
    margin-top: 50px;
    border-top: 2px solid var(--accent-color);
    padding-top: 20px;
}

footer {
    text-align: center;
    font-size: 0.7rem;
    margin-top: 50px;
    opacity: 0.8;
}

/* Specific style for the footer link */
footer a {
    color: #80719e !important; /* Force the specific purple color */
    text-decoration: none;
    transition: opacity 0.2s;
    font-weight: 600;
}

footer a:hover {
    opacity: 1;
    text-decoration: underline;
}

/* Giscus Specific Overrides to match theme */
.giscus-frame {
    width: 100%;
    border: none;
}

/* Floating Comments Button */
#floating-comments-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: var(--accent-color);
    color: var(--bg-color);
    border: none;
    padding: 12px 20px;
    border-radius: 30px;
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    z-index: 1000;
    transition: transform 0.2s, background-color 0.3s, color 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

#floating-comments-btn:hover {
    transform: translateY(-3px);
    opacity: 0.9;
}

/* Icon styling */
#floating-comments-btn::before {
    content: '💬';
    font-size: 1.1rem;
}
