* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: "Meiryo", "メイリオ", sans-serif;
    background: #2D2D2D;
    color: #F4F4F4;
    overflow: hidden;
}

#auth-screen {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background: #2D2D2D;
}

.auth-card {
    background: #FFFFFF;
    color: #2D2D2D;
    padding: 35px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    text-align: center;
    width: 360px;
    border-top: 6px solid #00A9E0;
}

.auth-card h1 {
    margin-bottom: 12px;
    color: #8031A7;
}

.auth-card input,
select {
    width: 100%;
    padding: 12px;
    margin: 10px 0;
    border: 1px solid #2D2D2D;
    border-radius: 6px;
    font-size: 14px;
    font-family: "Meiryo", sans-serif;
    background: #F4F4F4;
    color: #2D2D2D;
}

.btn-group {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

button {
    padding: 12px;
    background: #00A9E0;
    color: #FFFFFF;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    font-family: "Meiryo", sans-serif;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

button:hover:not(:disabled) {
    filter: brightness(1.1);
    transform: translateY(-1px);
}

button:active:not(:disabled) {
    transform: translateY(1px);
}

button:disabled {
    background: #F4F4F4 !important;
    color: #2D2D2D !important;
    cursor: not-allowed;
    opacity: 0.6;
}

.btn-secondary {
    background: #8031A7;
    color: #FFFFFF;
}

.msg {
    margin-top: 10px;
    font-size: 13px;
    color: #DA1884;
}

.room-item {
    background: #FFFFFF;
    color: #2D2D2D;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-left: 6px solid #00B2A9;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

header {
    background: #2D2D2D;
    padding: 12px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 4px solid #00A9E0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    z-index: 10;
}

header h2 {
    color: #FFFFFF;
}

.board-container {
    background: #F4F4F4;
}

.sidebar {
    background: #2D2D2D;
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex-shrink: 0;
    overflow-y: auto;
    border-right: 2px solid #F4F4F4;
}

.panel {
    background: #FFFFFF;
    color: #2D2D2D;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    border-top: 4px solid #8031A7;
}

.panel h3 {
    font-size: 14px;
    margin-bottom: 12px;
    color: #2D2D2D;
    border-bottom: 2px solid #F4F4F4;
    padding-bottom: 6px;
}

.resource-vertical-grid {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 5px;
}

.res-row {
    background: #F4F4F4;
    color: #2D2D2D;
    padding: 10px 15px;
    border-radius: 6px;
    font-size: 15px;
    font-weight: bold;
    display: flex;
    align-items: center;
}

.res-row .emoji {
    font-size: 20px;
    margin-right: 12px;
}

.res-row .val {
    margin-left: auto;
    font-size: 20px;
    color: #8031A7;
}

.cost-guide {
    background: #F4F4F4;
    color: #2D2D2D;
    padding: 12px;
    border-radius: 6px;
    font-size: 13px;
    line-height: 1.7;
    border: 1px dashed #00A9E0;
}

.chat-input {
    display: flex;
    gap: 6px;
}

.chat-input input {
    flex: 1;
    padding: 10px;
    border-radius: 6px;
    border: 1px solid #2D2D2D;
    font-family: "Meiryo", sans-serif;
    background: #FFFFFF;
    color: #2D2D2D;
}

.chat-input button {
    background: #00B2A9;
}

#chat-logs {
    background: #FFFFFF;
    color: #2D2D2D;
    border-radius: 6px;
    padding: 10px;
    border: 1px solid #F4F4F4;
}

#chat-logs::-webkit-scrollbar {
    width: 8px;
}

#chat-logs::-webkit-scrollbar-track {
    background: #F4F4F4;
}

#chat-logs::-webkit-scrollbar-thumb {
    background: #00A9E0;
    border-radius: 4px;
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(45, 45, 45, 0.85);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.overlay-box {
    background: #FFFFFF;
    color: #2D2D2D;
    padding: 35px;
    border-radius: 12px;
    text-align: center;
    width: 420px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    border-top: 6px solid #DA1884;
}

@media (max-width: 900px) {
    .main-layout {
        flex-direction: column;
        overflow-y: auto;
    }

    .sidebar {
        width: 100% !important;
        border: none !important;
    }
}