/* --- index.html (방송 오버레이) 스타일 --- */

body {
    margin: 0;
    font-family: 'Malgun Gothic', 'Apple SD Gothic Neo', sans-serif;
    background-color: transparent; /* 방송 오버레이를 위해 배경은 항상 투명 */
}

/* 컨테이너에서 배경과 테두리를 모두 제거 */
.container {
    text-align: center;
    padding: 10px;
    background: rgba(0, 0, 0, 0.4); /* 반투명 배경 (가독성↑) */
    border-radius: 10px; /* 모서리 둥글게 */
    display: inline-block;
}

.title {
    font-family: 'Nanum Gothic', sans-serif;
    font-size: 32px;       /* 제목 크기 */
    font-weight: bold;     /* 굵게 */
    color: #ffffff;        /* 흰색 글자 */
    text-shadow: 2px 2px 6px rgba(0,0,0,0.8); /* 글자 그림자 */
    margin-bottom: 5px;
}

.amount-display {
    font-family: 'Nanum Gothic', sans-serif;
    font-size: 64px;       /* 금액 크게 */
    font-weight: bold;
    color: #ffeb3b;        /* 강조 색 (노란색) */
    text-shadow: 3px 3px 8px rgba(0,0,0,0.9); /* 금액에 진한 그림자 */
}


/* --- admin.html (관리자 페이지) 스타일 --- */

/* 전체 페이지 배경 및 기본 폰트 설정 */
body.admin-page {
    background-color: #f4f6f9; /* 부드러운 회색 배경 */
    font-family: 'Malgun Gothic', 'Apple SD Gothic Neo', system-ui, sans-serif;
    color: #333;
    line-height: 1.6;
}

/* 콘텐츠를 중앙에 모으는 컨테이너 */
.admin-container {
    max-width: 700px;
    margin: 40px auto; /* 상하 여백 및 중앙 정렬 */
    padding: 0 20px;
}

/* 메인 타이틀 */
.admin-container h1 {
    text-align: center;
    color: #212529;
    margin-bottom: 30px;
    font-weight: 600;
}

/* 모든 섹션을 감싸는 카드 스타일 */
.card {
    background: #ffffff;
    padding: 25px 30px;
    border-radius: 8px; /* 부드러운 모서리 */
    box-shadow: 0 4px 12px rgba(0,0,0,0.08); /* 은은한 그림자 */
    margin-bottom: 25px;
    border: 1px solid #e9ecef; /* 옅은 테두리 */
}

/* 카드 내부 제목 */
.card h2 {
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 1.25rem;
    font-weight: 600;
    padding-bottom: 15px;
    border-bottom: 1px solid #e9ecef; /* 구분선 */
}

/* 현재 누적 상금 표시 */
#currentAmountDisplay {
    font-size: 2rem;
    font-weight: 700;
    color: #007bff; /* 파란색 포인트 */
    display: block;
    text-align: center;
    margin-bottom: 20px;
}

/* 입력 필드와 버튼 그룹 */
.input-group {
    display: flex;
    margin-bottom: 12px;
}

.input-group input[type="number"],
.input-group input[type="text"] {
    flex-grow: 1;
    padding: 12px 15px;
    border: 1px solid #ced4da;
    border-radius: 5px;
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

/* 입력 필드 포커스 시 효과 */
.input-group input[type="number"]:focus,
.input-group input[type="text"]:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.2);
    outline: none;
}

/* 공통 버튼 스타일 */
.input-group button, .reset-btn {
    padding: 12px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    color: white;
    transition: filter 0.2s;
    margin-left: 10px; /* 입력창과의 간격 */
}
.input-group button:hover, .reset-btn:hover {
    filter: brightness(90%); /* 호버 시 살짝 어두워지는 효과 */
}

/* 버튼별 색상 정의 */
#setAmountBtn, #winnerBtn { background-color: #007bff; } /* 파란색 */
#addAmountBtn { background-color: #28a745; width: 100%; margin-left: 0; } /* 초록색 */
.reset-btn { background-color: #ffc107; color: #212529; width: 100%; } /* 노란색 */


/* 설명 텍스트 */
.description {
    font-size: 0.9em;
    color: #6c757d;
    line-height: 1.5;
    background-color: #f8f9fa;
    padding: 10px 15px;
    border-radius: 5px;
    margin-top: 10px;
}

/* 관리자 페이지 하이런 기준표 */
.admin-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}
.admin-table th, .admin-table td {
    border: 1px solid #e9ecef;
    padding: 12px;
    text-align: center;
}
.admin-table th {
    background-color: #f8f9fa;
    font-weight: 600;
}

/* 당첨자 명단 리스트 */
#winnersList {
    list-style: none;
    padding: 0;
    margin: 0;
}
#winnersList li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #e9ecef;
}
#winnersList li:last-child {
    border-bottom: none;
}
#winnersList li span {
    color: #495057;
}
.delete-btn {
    padding: 5px 12px;
    font-size: 0.85rem;
    background-color: #dc3545; /* 빨간색 */
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    margin-left: 15px;
    transition: filter 0.2s;
}
.delete-btn:hover {
    filter: brightness(90%);
}

/* --- 아래 내용만 style.css 파일 맨 끝에 추가 --- */

/* 당첨자 목록 아이템 레이아웃 조정 */
#winnersList li {
    display: flex;
    justify-content: space-between; /* 내용과 버튼을 양쪽 끝으로 */
    align-items: center; /* 세로 중앙 정렬 */
    padding: 12px 10px; /* 패딩 조정 */
}

/* 삭제 버튼 스타일 */
.delete-btn {
    padding: 4px 10px;
    font-size: 13px;
    background-color: #dc3545; /* 빨간색 계열 */
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-left: 10px; /* 왼쪽 텍스트와의 간격 */
    transition: background-color 0.2s;
}

.delete-btn:hover {
    background-color: #c82333; /* 호버 시 더 진한 빨간색 */
}

/* --- hirun.html (하이런 기준표) 스타일 --- */
.hirun-container {
    /* 살짝 어두운 반투명 배경으로 가독성 확보 */
    background-color: rgba(0, 0, 0, 0.9); 
    color: white;
    padding: 20px 25px;
    width: 380px; /* 너비 살짝 조정 */
    box-sizing: border-box;
    border-radius: 10px; /* 부드러운 모서리 */
    
    /* 모든 텍스트에 일관된 그림자 효과 적용 */
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.hirun-title {
    font-size: 32px;
    font-weight: 900; /* 더 두껍게 */
    color: #fffb00; /* 밝은 노란색 */
    text-align: center;
    padding-bottom: 10px;
    margin-bottom: 10px;
    /* 제목과 내용 사이에 옅은 구분선 추가 */
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.hirun-notice {
    font-size: 15px;
    text-align: center;
    margin-bottom: 20px;
    line-height: 1.5;
    /* 설명 텍스트는 약간 투명하게 처리하여 덜 중요해 보이도록 */
    color: rgba(255, 255, 255, 0.85);
    font-style: italic;
}

.hirun-table {
    width: 100%;
    border-collapse: collapse; /* 테두리 합치기 */
    font-size: 22px; /* 폰트 크기 키움 */
}

/* 테이블 헤더(th)와 데이터(td)의 공통 스타일 */
.hirun-table th, .hirun-table td {
    padding: 12px 10px; /* 상하 여백을 늘려 행 간격 확보 */
    text-align: center;
    border-bottom: none; /* 모든 선 제거 */
}

/* 테이블 헤더(thead)에만 하단 구분선 추가 */
.hirun-table thead {
    border-bottom: 2px solid rgba(255, 255, 255, 0.5);
}

.hirun-table th {
    font-weight: bold;
    color: #ffffff; /* 헤더는 밝은 흰색 */
}

/* 짝수 번째 행에만 미세한 배경색을 주어 구분감 향상 */
.hirun-table tbody tr:nth-child(even) {
    background-color: rgba(255, 255, 255, 0.05);
}

/* 핸디 컬럼은 왼쪽 정렬 */
.hirun-table td:first-child {
    text-align: left;
    font-weight: 600;
}

/* 하이런 점수 컬럼은 오른쪽 정렬 */
.hirun-table td:last-child {
    text-align: right;
    font-family: 'Arial', sans-serif; /* 숫자는 다른 폰트로 더 명확하게 */
    color: #87CEEB; /* 스카이블루 색상으로 포인트 */
}