html, body {
    width: 100%;
    height: 100%;
}

.flexbox {
    width: 100%;
    height: 100%;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
}

.box {
    text-align: center;
    width: 100%;
}

.headline1, .headline2 {
    margin: 0;
    font-size: large;
}

p {
    margin-top: 0;
    margin-bottom: 0;
}

.error-text {
    color: red;
    display: none;
}

.guest-text {
    margin-top: 5%;
}

input[type="search"] {
    width: 100%;
    margin-top: 10px;
    padding: 10px;
    font-size: small;
    border-radius: 8px;
    border: solid 1px #d8e4ec;
    background-color: #f0f4fc;
}


button[type="submit"] {
    width: 100%;
    margin-top: 20px;
    padding: 8px;
    font-size: medium;
    font-weight: bold;
    color: white;
    border-radius: 8px;
    border: solid 1px #089c9c;
    background-color: #089c9c;
}

button[type="submit"]:hover {
    border: solid 1px #08aeae;
    background-color: #08aeae;
}

.guest-button {
    border: solid 1px #08529C !important;
    background-color: #08529C !important;
}

.guest-button:hover {
    border: solid 1px #095BAD !important;
    background-color: #095BAD !important;
}


/* メインのカードコンテナ */
.form-box {
    width: 350px;
    height: 480px;
    position: relative;
    background: #fff;
    padding: 10px;
    overflow: hidden; /* はみ出したフォームを隠す */
    border-radius: 20px;
    box-shadow: 0 0 20px rgba(0,0,0,0.2);
}

/* ボタン用コンテナ */
.button-box {
    width: 230px;
    margin: 35px auto;
    position: relative;
    box-shadow: 0 0 10px 5px rgba(0,0,0,0.05);
    border-radius: 30px;
    display: flex;
    justify-content: space-between;
}

/* 切り替えボタンのスタイル */
.toggle-btn {
    padding: 10px 30px;
    cursor: pointer;
    background: transparent;
    border: 0;
    outline: none;
    position: relative;
    font-weight: bold;
    color: #777;
    transition: color 0.5s;
}

/* 選択中の背景（スライドする色付きの背景） */
#btn-highlight {
    top: 0;
    left: 0;
    position: absolute;
    width: 110px;
    height: 100%;
    background: #089c9c;
    border-radius: 30px;
    transition: .5s;
}

/* 入力フォームの共通スタイル */
.input-group {
    top: 150px;
    position: absolute;
    width: 280px;
    transition: .5s;
}

/* 各フォームの初期位置 */
#login { left: 50px; }
#register { left: 450px; /* 最初は右側に隠しておく */ }

@media screen and (min-width: 768px) {
	/* 768px以上に適用されるCSS（PC用） */
    .headline1 {
        margin: 0;
        font-size: xx-large;
    }
    .headline2 {
        margin: 0;
        font-size: x-large;
    }

    input[type="search"] {
        padding: 16px;
    }


    button[type="submit"] {
        padding: 12px 16px;
    }

    /* メインのカードコンテナ */
    .form-box {
        width: 700px;
    }

    /* 入力フォームの共通スタイル */
    .input-group {
        top: 150px;
        position: absolute;
        width: 560px;
        transition: .5s;
    }

    /* 各フォームの初期位置 */
    #login { left: 100px; }
    #register { left: 900px; /* 最初は右側に隠しておく */ }
}