/* /css/form_style.css */

body { 
    background-color: #ecf0f1;
    font-family: Arial, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
    box-sizing: border-box; 
}

/* 各ページのコンテナ共通スタイル */
.login-form,
.form-container,
.confirm-container,
.message-box {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    width: 100%;
}

.form-container, .confirm-container, .login-container {
    width: 400px;
}
.message-box {
    max-width: 400px;
    text-align: center;
}

h1 { 
    text-align: center; 
    color: #333; 
    font-size: 1.8em;
}
.login-form h2 {
    text-align: center;
    margin-bottom: 30px;
    color: #2c3e50;
}

/* --- 登録フォーム (register.php) --- */
.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 5px; font-weight: bold; }
.form-group input { width: 100%; padding: 10px; border: 1px solid #ccc; border-radius: 4px; box-sizing: border-box; font-size: 16px; }
.btn-submit { width: 100%; padding: 12px; background-color: #3498db; color: white; border: none; border-radius: 4px; font-size: 16px; cursor: pointer; }
.btn-submit:hover { background-color: #2980b9; }
.error-list { list-style: none; padding: 15px; margin-bottom: 20px; background-color: #f8d7da; color: #721c24; border: 1px solid #f5c6cb; border-radius: 4px; }
.back-link { display: block; text-align: center; margin-top: 20px; }

/* --- 確認ページ (confirm.php) --- */
.confirm-container table { width: 100%; border-collapse: collapse; }
.confirm-container th, .confirm-container td { border: 1px solid #ddd; padding: 12px; text-align: left; word-break: break-all; }
.confirm-container th { background-color: #f9f9f9; width: 30%; }
.button-group { display: flex; justify-content: space-between; margin-top: 30px; }
.button-group .btn { padding: 12px 25px; border: none; border-radius: 4px; font-size: 16px; cursor: pointer; text-decoration: none; text-align: center; }
.button-group .btn-submit { background-color: #2ecc71; color: white; flex-grow: 1; margin-left: 10px;}
.button-group .btn-back { background-color: #95a5a6; color: white; flex-grow: 1; margin-right: 10px;}

/* --- 認証ページ (verify.php) --- */
.login-link { display: inline-block; margin-top: 20px; padding: 10px 20px; background-color: #3498db; color: white; text-decoration: none; border-radius: 4px; }


.optional-badge {
    display: inline-block;
    margin-left: 8px;
    padding: 2px 6px;
    font-size: 0.7em;
    font-weight: normal;
    background-color: #7f8c8d;
    color: white;
    border-radius: 4px;
    vertical-align: middle;
}

.btn-login {
    width: 100%;
    padding: 12px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: background-color 0.3s;
}
.btn-login:hover {
    background-color: #2980b9;
}
.error-message {
    background-color: #e74c3c;
    color: white;
    padding: 10px;
    border-radius: 5px;
    text-align: center;
    margin-bottom: 20px;
}

/* Googleサインインボタン用のスタイル */
.google-login-separator {
    display: flex;
    align-items: center;
    text-align: center;
    color: #888;
    margin: 20px 0;
}
/* 線の部分 */
.google-login-separator::before,
.google-login-separator::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #ddd;
}
/* 「または」の文字の両脇にスペースを設ける */
.google-login-separator:not(:empty)::before {
    margin-right: .5em;
}
.google-login-separator:not(:empty)::after {
    margin-left: .5em;
}

.btn-google-login {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px; /* アイコンとテキストの隙間 */
    width: 100%;
    padding: 10px;
    background-color: #ffffff;
    color: #444; /* Googleの推奨色に近い */
    border: 1px solid #ddd;
    border-radius: 5px;
    cursor: pointer;
    font-size: 15px;
    font-weight: bold;
    text-decoration: none;
    transition: background-color 0.3s, border-color 0.3s;
    box-sizing: border-box;
}

.btn-google-login:hover, .btn-line-login:hover {
    background-color: #f7f7f7;
    border-color: #ccc;
}

.btn-google-login svg {
    width: 20px;
    height: 20px;
}
.btn-line-login {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 15px;
	width: 100%;
	padding: 10px;
	color: #06C755; /* LINEのブランドカラー */
	border: 1px solid #ddd;
	border-radius: 5px;
	cursor: pointer;
	font-size: 15px;
	font-weight: bold;
	text-decoration: none;
	transition: background-color 0.3s;
	box-sizing: border-box;
    margin-top: 10px; /* Googleボタンとの間隔 */
}
.btn-line-login .line-icon {
	width: 22px;
	height: 22px;
/*	fill: #ffffff; /* アイコンの色 */
}
.password-strength {
	margin-top: 8px;
	display: flex;
	align-items: center;
	gap: 10px;
}
.strength-bar {
	flex-grow: 1;
	height: 8px;
	background-color: #eee;
	border-radius: 4px;
	transition: background-color 0.3s;
}
.strength-bar.weak { background-color: #e74c3c; }
.strength-bar.medium { background-color: #f1c40f; }
.strength-bar.strong { background-color: #2ecc71; }
.strength-text { font-size: 0.9em; font-weight: bold; }
.password-rules { font-size: 0.8em; color: #666; margin-top: 5px; list-style-position: inside; padding-left: 0; }


/* テキスト選択の無効化 */
* {
	-webkit-user-select: none;
	-moz-user-select: none;
	-ms-user-select: none;
	user-select: none;
}


/* --- レスポンシブ対応 --- */
@media (max-width: 768px) {
    body { padding: 10px 0; }
    h1 { font-size: 1.5em; }
    
    .form-container, .confirm-container, .message-box {
        padding: 20px;
        margin: 0 10px;
    }

    /* 確認ページのテーブル */
    .confirm-container th, .confirm-container td { padding: 8px; }
    .confirm-container th { width: 100%; display: block; border-bottom: none; }
    .confirm-container td { width: 100%; display: block; }
    .confirm-container tr { display: block; margin-bottom: 15px; border: 1px solid #ddd; border-radius: 4px; }
    
    /* 確認ページのボタン */
    .button-group {
        flex-direction: column-reverse;
        gap: 15px;
    }
    .button-group .btn-submit, .button-group .btn-back {
        margin: 0;
    }
}