:root {
    --bg-color: #f8fafc;
    --container-bg: rgba(255, 255, 255, 0.9);
    --text-color: #1e293b;
    --shadow-color: rgba(0, 0, 0, 0.05);
    --btn-bg: linear-gradient(135deg, #3b82f6, #2563eb);
    --btn-hover: linear-gradient(135deg, #2563eb, #1d4ed8);
    --toggle-bg: #ffffff;
    --input-bg: #ffffff;
    --accent-color: #3b82f6;
    --border-radius: 20px;
}

.dark-mode {
    --bg-color: #0f172a;
    --container-bg: rgba(30, 41, 59, 0.95);
    --text-color: #f1f5f9;
    --shadow-color: rgba(0, 0, 0, 0.3);
    --btn-bg: linear-gradient(135deg, #4f46e5, #4338ca);
    --btn-hover: linear-gradient(135deg, #4338ca, #3730a3);
    --toggle-bg: #1e293b;
    --input-bg: #1e293b;
    --accent-color: #6366f1;
}

body {
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-color: var(--bg-color);
    background-image: radial-gradient(circle at top right, rgba(59, 130, 246, 0.1), transparent 400px);
    background-attachment: fixed;
    color: var(--text-color);
    transition: all 0.3s ease;
    margin: 0;
}

.top-controls {
    display: flex;
    justify-content: center;
    gap: 20px;
    align-items: center;
    margin-bottom: 30px;
    width: 100%;
}

#language-select {
    padding: 12px 20px;
    border-radius: 16px;
    border: 2px solid var(--shadow-color);
    background-color: var(--input-bg);
    color: var(--text-color);
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
}

#theme-toggle {
    background: var(--toggle-bg);
    border: 2px solid var(--shadow-color);
    border-radius: 16px;
    width: 50px;
    height: 50px;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 10px var(--shadow-color);
    transition: all 0.3s ease;
}

#theme-toggle:hover, #language-select:hover {
    transform: scale(1.05);
    border-color: var(--accent-color);
}

.container {
    text-align: center;
    padding: 50px 30px;
    border-radius: 32px;
    background-color: var(--container-bg);
    backdrop-filter: blur(12px);
    box-shadow: 0 25px 50px -12px var(--shadow-color);
    width: 95%;
    max-width: 600px;
    margin: 60px 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

h1 {
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 24px;
    letter-spacing: -1px;
}

.how-to-use-top {
    background: rgba(59, 130, 246, 0.05);
    padding: 20px;
    border-radius: 20px;
    margin-bottom: 32px;
    border-left: 4px solid var(--accent-color);
    text-align: left;
}

.how-to-use-top h2 {
    font-size: 16px;
    font-weight: 700;
    margin: 0 0 8px 0;
    color: var(--accent-color);
}

.how-to-use-top p {
    font-size: 14px;
    margin: 0;
    line-height: 1.5;
    opacity: 0.8;
}

.generator-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    margin-bottom: 40px;
}

.input-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.input-group label {
    font-weight: 600;
    font-size: 15px;
}

#set-count {
    width: 70px;
    padding: 12px;
    border-radius: 12px;
    border: 2px solid var(--shadow-color);
    background-color: var(--input-bg);
    color: var(--text-color);
    font-weight: 700;
    text-align: center;
}

#generate-btn {
    width: 100%;
    padding: 18px;
    border-radius: 18px;
    border: none;
    background: var(--btn-bg);
    color: white;
    font-weight: 700;
    font-size: 18px;
    cursor: pointer;
    box-shadow: 0 10px 15px -3px rgba(59, 130, 246, 0.3);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

#generate-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 25px -5px rgba(59, 130, 246, 0.4);
}

#lotto-sets-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 30px;
    max-height: 480px;
    overflow-y: auto;
    padding-right: 8px;
}

#lotto-sets-container::-webkit-scrollbar {
    width: 6px;
}

#lotto-sets-container::-webkit-scrollbar-thumb {
    background-color: var(--shadow-color);
    border-radius: 10px;
}

.lotto-set {
    background-color: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--shadow-color);
    padding: 12px;
    border-radius: 16px;
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.lotto-number {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 15px;
    font-weight: 700;
    color: #fff;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    animation: popIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) both;
}

@keyframes popIn {
    0% { transform: scale(0); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

.comment-section, .info-section, .footer-section {
    margin-top: 50px;
    padding-top: 30px;
    border-top: 1px solid var(--shadow-color);
    text-align: left;
}

h2 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--text-color);
}

#partnership-form input,
#partnership-form textarea,
#comment-form textarea {
    width: 100%;
    padding: 14px;
    border-radius: 14px;
    border: 1px solid var(--shadow-color);
    background-color: var(--input-bg);
    color: var(--text-color);
    font-size: 14px;
    box-sizing: border-box;
    margin-bottom: 12px;
}

#form-submit, #comment-submit {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 14px;
    font-weight: 600;
    cursor: pointer;
}

#form-submit { background-color: #10b981; color: white; }
#comment-submit { background-color: var(--accent-color); color: white; }

.comment-item {
    background-color: rgba(255, 255, 255, 0.03);
    padding: 16px;
    border-radius: 16px;
    margin-bottom: 12px;
    border: 1px solid var(--shadow-color);
}

.comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.comment-item .author {
    font-weight: bold;
    font-size: 14px;
    color: var(--btn-bg);
}

.comment-item .author.admin-author {
    color: #ef4444;
    display: flex;
    align-items: center;
    gap: 6px;
}

.comment-item .author.admin-author::before {
    content: '★';
    font-size: 14px;
}

.delete-comment-btn {
    background: none;
    border: none;
    color: #ef4444;
    font-size: 20px;
    cursor: pointer;
    line-height: 1;
    padding: 0 4px;
}

.disclaimer-box {
    margin-top: 30px;
    padding: 20px;
    background: rgba(239, 68, 68, 0.05);
    border-radius: 20px;
    border: 1px dashed rgba(239, 68, 68, 0.3);
}

#disclaimer-text {
    font-size: 13px;
    color: #ef4444;
    font-weight: 600;
    margin: 0;
    line-height: 1.6;
    text-align: center;
}

.footer-section p {
    font-size: 13px;
    line-height: 1.6;
    opacity: 0.7;
}