* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-size:1rem;
}

body {
    background-color: #1a1a1a;
    color: #e0e0e0;
    font-family: sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100dvh;
}

.container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    padding: 20px;
}

.controls {
    background: #404040;
    color: #ffffff;
    padding: 16px 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
}

.input-group {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
}

select, input[type="number"] {
    background: #1a1a1a;
    color: #fff;
    border: 1px solid #555;
    padding: 6px 8px;
    border-radius: 4px;
    font-size: 14px;
}

input[type="number"] {
    width: 65px;
    text-align: right;
}

#apply-btn {
    margin-top: 4px;
    padding: 8px 20px;
    background: #e00000;
    color: #ffffff;
    border: none;
    font-size: 14px;
    cursor: pointer;
}

#apply-btn:hover {
    background: #e74c3c;
}

/* モード切り替えボタン */
.mode-switch {
    display: flex;
    background: #2a2a2a;
    padding: 4px;
    gap: 4px;
}

.mode-btn {
    padding: 8px 16px;
    background: transparent;
    color: #999;
    border: none;
    font-size: 13px;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

.mode-btn:hover {
    color: #ddd;
}

.mode-btn.active {
    background: #444;
    color: #fff;
    font-weight: bold;
}

.hourglass-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.status-text {
    font-size: 14px;
    color: #eeeeee;
    text-align: center;
    line-height: 1.6;
    min-height: 4.8em;
}

#back-button {
    font-size: 1.4rem;
    color: #ffffff;
    text-decoration-line: none;
    background-color: #00b06b;
    width:auto;
    height:auto;
}
#back-button:hover {
    filter: brightness(1.2);
}

@media (orientation:portrait){
    .input-group {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .input-group label {
        width: 100%;
        text-align: center;
        margin-bottom: 4px;
    }
}