/* 기본 초기화 */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background-color: #f8f9fa;
    color: #1a1a1a;
    font-family: -apple-system, sans-serif;
    padding: 30px 15px;
    display: flex;
    justify-content: center;
}

.container {
    width: 100%;
    max-width: 750px;
    background: #ffffff;
    padding: 35px;
    border: 1px solid #000;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #000;
}

h1 { font-size: 20px; font-weight: 800; }
.mode-tag { font-size: 11px; font-weight: bold; border: 1px solid #000; padding: 2px 6px; }

.section { margin-bottom: 25px; }
.label { font-size: 12px; font-weight: 700; margin-bottom: 8px; text-transform: uppercase; }

/* 입력창 공통 스타일 */
input, textarea {
    width: 100%;
    border: 1px solid #000;
    padding: 12px;
    font-family: "Consolas", "Monaco", monospace;
    font-size: 16px;
    outline: none;
}

/* 스코어보드 특화 스타일 */
.scoreboard-container {
    border: 1px solid #000;
}

.scoreboard-header {
    background: #f1f3f5;
    padding: 8px 12px;
    font-family: "Consolas", monospace;
    font-weight: bold;
    font-size: 16px;
    letter-spacing: 2px;
    border-bottom: 1px solid #000;
    user-select: none; /* 텍스트 선택 불가 (수정 방지) */
}

#scoreboard {
    border: none;
    height: 85px;
    line-height: 1.8;
    letter-spacing: 2px;
}

/* 라인업 및 교체 스타일 */
.lineup-item { margin-bottom: 10px; }
.row { display: flex; gap: 8px; align-items: center; margin-bottom: 4px; }
.num { width: 25px; font-weight: bold; }
.btn-sub { 
    padding: 4px 10px; font-size: 11px; background: #fff; 
    border: 1px solid #ccc; cursor: pointer; transition: 0.2s;
}
.btn-sub:hover { background: #000; color: #fff; border-color: #000; }

.sub-row { display: flex; align-items: center; gap: 8px; margin-left: 33px; margin-bottom: 5px; }

/* 하단 버튼 */
.controls { display: flex; gap: 10px; margin-top: 30px; }
button.main { flex: 2; padding: 16px; background: #000; color: #fff; border: none; font-weight: bold; font-size: 16px; cursor: pointer; }
button.reset { flex: 1; background: #fff; border: 1px solid #ff4d4f; color: #ff4d4f; font-weight: bold; cursor: pointer; }

/* 토스트 메시지 */
#toast { 
    position: fixed; bottom: 30px; left: 50%; transform: translateX(-50%); 
    background: rgba(0,0,0,0.85); color: white; padding: 10px 25px; 
    font-size: 14px; opacity: 0; transition: 0.3s; pointer-events: none;
}