/* --- Font Definition --- */
@font-face {
    font-family: 'Pretendard';
    src: url('./fonts/PretendardVariable.woff2') format('woff2-variations');
    font-weight: 400 700;
}

@font-face {
    font-family: 'Paperlogy';
    src: url('./fonts/Paperlogy-4Regular.woff2') format('woff2');
    font-weight: normal;
}

/* --- Color Theme Variables --- */
:root {
    --mint-green: #A0D2DB; --mint-green-darker: #7EACB3; --dark-bg: #F8F9FA;
    --dark-surface: #FFFFFF; --light-text: #343A40; --secondary-text: #6C757D;
    --border-color: #CED4DA; --button-active-bg: #e9ecef;
}

body[data-theme="nordic-noir"] {
    --mint-green: #88C0D0; --mint-green-darker: #70A9BF; --dark-bg: #2E3440;
    --dark-surface: #3B4252; --light-text: #ECEFF4; --secondary-text: #D8DEE9;
    --border-color: #4C566A; --button-active-bg: #292E39;
}

/* --- General & Reset --- */
*, *::before, *::after {
    box-sizing: border-box;
}

body {
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    margin: 0;
    background-color: var(--dark-bg);
    color: var(--light-text);
    line-height: 1.7;
    transition: background-color 0.3s ease, color 0.3s ease;
    /* [수정] 가로 스크롤바 원천 차단 */
    overflow-x: hidden;
}

/* --- Layout --- */
.manual-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 1.5rem 0 1.5rem;
}

header {
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

article section {
    margin-bottom: 3rem;
}

article p, article li {
    text-align: justify;
}

footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 10;
    background-color: var(--dark-surface);
    border-top: 1px solid var(--border-color);
    padding: 0.75rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    color: var(--secondary-text);
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.footer-spacer {
    height: 4rem; 
}

/* --- Typography --- */
h1, h2, h3 {
    font-family: 'Paperlogy', serif;
    font-weight: normal;
    color: var(--light-text);
}

h1 {
    font-size: 2.5rem;
    margin: 0;
    line-height: 1.2;
}

h2 {
    font-size: 1.8rem;
    margin-top: 0;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

h3 {
    font-size: 1.3rem;
    color: var(--secondary-text);
}

p {
    margin-top: 0;
    margin-bottom: 1rem;
}

a {
    color: var(--mint-green);
    text-decoration: none;
}

ul, ol {
    padding-left: 1.5rem;
}

li {
    margin-bottom: 0.5rem;
}

strong {
    color: var(--light-text);
}

code {
    background-color: var(--button-active-bg);
    padding: 0.2em 0.4em;
    border-radius: 4px;
    font-size: 0.9em;
}

.note {
    background-color: var(--dark-surface);
    border-left: 4px solid var(--mint-green-darker);
    padding: 1rem 1.5rem;
    border-radius: 4px;
    font-size: 0.9rem;
    color: var(--secondary-text);
}

/* --- Components --- */
.language-selector button {
    font-family: 'Pretendard', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-color);
    background-color: transparent;
    color: var(--secondary-text);
    border-radius: 2rem;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s;
}

.language-selector button.active {
    background-color: var(--mint-green);
    border-color: var(--mint-green);
    color: var(--dark-bg);
}

.screenshot-placeholder {
    width: 100%;
    margin: 2rem 0;
    border: 1px solid var(--border-color);
    background-color: var(--dark-surface);
    padding: 1rem;
    border-radius: 8px;
}

.screenshot-placeholder img {
    max-width: 100%;
    height: auto;
    display: block;
    border-radius: 4px;
}

.copyright {
    flex-shrink: 0;
}

.theme-selector {
    display: flex;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    background-color: var(--dark-surface);
}

.theme-btn {
    height: 38px;
    background-color: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 15px;
    transition: background-color 0.2s;
}
.theme-btn:first-child { 
    border-right: 1px solid var(--border-color); 
}
.theme-btn.active { 
    background-color: var(--button-active-bg); 
}
.theme-btn:not(.active):hover { 
    background-color: color-mix(in srgb, var(--dark-surface) 80%, var(--mint-green) 20%); 
}
.theme-btn .color-patch {
    width: 16px;
    height: 16px;
    border-radius: 4px;
    border: 1px solid var(--border-color);
}
.theme-btn[data-theme="aetherial-light"] .color-patch {
    background-color: #F8F9FA;
}
.theme-btn[data-theme="nordic-noir"] .color-patch {
    background-color: #2E3440;
}

.copyright a {
    font-weight: 600;
    color: var(--light-text); 
    text-decoration: none;
    transition: color 0.2s;
}

.copyright a:hover {
    color: var(--mint-green);
    text-decoration: underline;
}