/* ==================================
   モダンログイン画面スタイル (Figmaデザイン準拠)
   レスポンシブ対応: スマホ(~767px), タブレット(768px~1023px), PC(1024px~)
   ================================== */

/* リセット＆基本設定 */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

html, body {
	height: 100%;
	font-family: "メイリオ", Meiryo, "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", "ＭＳ Ｐゴシック", Osaka, sans-serif;
	font-size: 12px;
	font-size: 78%;
	line-height: 1.34;
}

body {
	background: #ffffff;
	min-height: 100vh;
	padding: 0;
}

/* リンクスタイルのリセット */
a,
a:link,
a:visited {
	color: inherit;
	text-decoration: none;
}

a:hover {
	text-decoration: none;
}

/* Benesseヘッダー */
.benesse-header {
	background: #ffffff;
	border-bottom: 1px solid #e0e0e0;
	padding: 12px 0;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.benesse-header-inner {
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 20px;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.benesse-logo {
	flex-shrink: 0;
}

.benesse-logo a,
.benesse-logo a:link,
.benesse-logo a:visited {
	display: block;
	line-height: 0;
}

.benesse-logo img {
	display: block;
	height: 21px;
	width: auto;
}

.benesse-nav ul {
	display: flex;
	gap: 20px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.benesse-nav li {
	margin: 0;
}

.benesse-nav a,
.benesse-nav a:link,
.benesse-nav a:visited {
	color: #333;
	text-decoration: none;
	font-size: 13px;
	transition: color 0.2s ease;
	white-space: nowrap;
}

.benesse-nav a:hover {
	color: #7c4dff;
	text-decoration: underline;
}

/* メインコンテナ */
.login-container {
	width: 100%;
	max-width: 420px;
	margin: 0 auto;
	padding: 40px 20px;
	display: flex;
	flex-direction: column;
	align-items: center;
	min-height: calc(100vh - 60px);
}

/* 785px以上：PCレイアウト */
@media screen and (min-width: 785px) {
	.login-container {
		max-width: 800px;
	}
}

/* ログインカード */
.login-card {
	background: #ffffff;
	border-radius: 16px;
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
	padding: 32px;
	animation: fadeInUp 0.5s ease-out;
}

@keyframes fadeInUp {
	from {
		opacity: 0;
		transform: translateY(20px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* ヘッダー */
.login-header {
	text-align: center;
	margin-bottom: 32px;
	padding-bottom: 20px;
	border-bottom: 2px solid #f0f0f0;
}

.login-title {
	font-size: 28px;
	font-weight: 700;
	color: #1a1a1a;
	margin-bottom: 8px;
	letter-spacing: 0.5px;
}

.login-subtitle {
	font-size: 13px;
	color: #666;
	line-height: 1.6;
	margin: 0;
}

/* エラーメッセージ */
.error-message {
	background: #fff3f3;
	border: 1px solid #ffcdd2;
	border-radius: 8px;
	padding: 12px 16px;
	margin-bottom: 20px;
	color: #c62828;
	font-size: 13px;
	line-height: 1.6;
}

.error-message ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.error-message li {
	margin: 4px 0;
}

/* インフォメッセージ（学年の確認など） - フォームグループスタイル */
.info-form-group {
	border-bottom: 1px solid #f0f0f0;
	padding-bottom: 20px;
}

.info-label {
	color: #333;
	font-weight: 600;
}

.info-content {
	font-size: 13px;
	line-height: 1.8;
	text-align: left;
}

/* フォームグループ */
.form-group {
	margin-bottom: 24px;
}

.form-group-content {
	width: 100%;
}

.form-label {
	display: flex;
	align-items: center;
	justify-content: flex-start;
	margin-bottom: 8px;
	font-weight: 600;
	font-size: 14px;
	color: #333;
}

.label-text {
	margin-right: 6px;
}

.label-badge {
	display: inline-block;
	background: #ff5252;
	color: #ffffff;
	font-size: 10px;
	font-weight: 600;
	padding: 3px 8px;
	border-radius: 3px;
	letter-spacing: 0.5px;
	line-height: 1;
	flex-shrink: 0;
	white-space: nowrap;
}

/* 入力フィールド */
.input-wrapper {
	position: relative;
	display: block;
	width: 100%;
}

.form-input {
	width: 100%;
	padding: 12px 16px;
	border: 2px solid #e0e0e0;
	border-radius: 8px;
	font-size: 15px;
	color: #333;
	transition: all 0.3s ease;
	background: #fafafa;
	box-sizing: border-box;
}

input[type="text"].form-input:focus,
input[type="password"].form-input:focus {
	outline: none !important;
	border: 3px solid #000000 !important;
	background: #ffffff !important;
	box-shadow: none !important;
	padding: 10px 14px !important;
}

.form-input::placeholder {
	color: #aaa;
	font-size: 14px;
}

/* IDドロップダウンボタン */
.id-dropdown-button {
	position: absolute;
	top: 50%;
	right: 12px;
	transform: translateY(-50%);
	width: 36px;
	height: 36px;
	cursor: pointer;
	border-radius: 6px;
	transition: opacity 0.2s ease;
	z-index: 10;
}

.id-dropdown-button:hover {
	opacity: 0.8;
}

/* ID入力欄はボタン分のパディングを追加 */
#loginid {
	padding-right: 56px;
}

/* パスワード入力欄は通常のパディング */
#password {
	width: 100%;
	padding: 12px 16px;
	border: 2px solid #e0e0e0;
	border-radius: 8px;
	font-size: 15px;
	color: #333;
	transition: all 0.3s ease;
	background: #fafafa;
	box-sizing: border-box;
}

#password:focus {
	outline: none !important;
	border: 3px solid #000000 !important;
	background: #ffffff !important;
	box-shadow: none !important;
	padding: 11px 15px !important;
}

/* 注意書き */
.form-note {
	display: block;
	margin-top: 8px;
	font-size: 12px;
	color: #777;
	line-height: 1.5;
	text-align: left;
}

.form-link,
.form-link:link,
.form-link:visited {
	color: #7c4dff;
	text-decoration: none;
	font-weight: 500;
	transition: color 0.2s ease;
}

.form-link:hover {
	color: #5e35b1;
	text-decoration: underline;
}

/* チェックボックス */
.checkbox-label {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-top: 12px;
	cursor: pointer;
	font-size: 13px;
	color: #555;
	user-select: none;
}

.form-checkbox {
	width: 18px;
	height: 18px;
	cursor: pointer;
	accent-color: #7c4dff;
}

.checkbox-label:hover {
	color: #333;
}

/* パスワード忘れ */
.password-forgot {
	margin-top: 8px;
	margin-bottom: 8px;
	font-size: 13px;
	color: #666;
	text-align: left;
}


/* 非会員向けリンク */
.non-member-link {
	margin: 20px 0 20px;
	text-align: center;
}

.non-member-button,
.non-member-button:link,
.non-member-button:visited {
	display: block;
	width: 100%;
	border: 2px solid #0365C8;
	background-color: #ffffff;
	color: #0365C8;
	border-radius: 5px;
	text-decoration: none;
	padding: 10px 20px;
	cursor: pointer;
	transition: all 0.2s ease;
	box-sizing: border-box;
	white-space: nowrap;
}

.non-member-button:hover {
	background-color: #f0f8ff;
	text-decoration: none;
}

/* PC表示時のサイズ調整（ログインボタンと同じ幅） */
@media screen and (min-width: 700px) {
	.non-member-link {
		width: 250px;
		margin: 20px auto;
	}
}

/* フォームフッター */
.form-footer {
	text-align: center;
	padding-top: 16px;
	margin-top: 30px;
	border-top: 1px solid #f0f0f0;
}

.footer-link,
.footer-link:link,
.footer-link:visited {
	display: inline-block;
	margin: 6px 12px;
	font-size: 12px;
	color: #0070cb;
	text-decoration: none;
	transition: color 0.2s ease;
}

.footer-link:hover {
	color: #ff0000;
	text-decoration: underline;
}

/* ページフッター */
.login-footer {
	text-align: center;
}

.login-footer p {
	font-size: 12px;
	color: #999;
	margin: 0;
}

/* IDリスト（プルダウン） */
#idlist {
	position: absolute;
	top: 100%;
	left: 0;
	right: 0;
	background: #ffffff;
	border: 2px solid #7c4dff;
	border-radius: 8px;
	margin-top: 4px;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
	z-index: 1000;
	max-height: 200px;
	overflow-y: auto;
	text-align: left;
}

#idlist li,
#idlist div,
#idlist a {
	text-align: left;
	padding: 8px 12px;
	cursor: pointer;
	transition: background 0.2s ease;
}

#idlist li:hover,
#idlist div:hover,
#idlist a:hover {
	background: #e0e0e0;
}

/* ============================================
   レスポンシブ対応（元のshobtg.jspの仕様に準拠）
   785px以上: PC / 784px以下: スマホ・タブレット
   ============================================ */

/* PC (785px以上) */
@media screen and (min-width: 785px) {
	.benesse-header {
		padding: 16px 0;
	}
	
	.benesse-header-inner {
		padding: 0 40px;
	}
	
	.benesse-nav a {
		font-size: 14px;
	}
	
	.login-container {
		padding: 60px 40px;
	}
	
	.login-card {
		padding: 56px 64px;
	}
	
	.login-header {
		margin-bottom: 40px;
		padding-bottom: 28px;
	}
	
	.login-title {
		font-size: 32px;
	}
	
	.login-subtitle {
		font-size: 15px;
	}
	
	.form-group {
		margin-bottom: 32px;
		display: flex;
		align-items: flex-start;
		gap: 24px;
	}
	
	.form-label {
		font-size: 15px;
		margin-bottom: 0;
		flex-shrink: 0;
		width: 220px;
		padding-top: 12px;
		display: flex;
		flex-direction: row;
		align-items: center;
		gap: 8px;
		justify-content: flex-start;
	}
	
	.form-label .label-text {
		flex: 0 0 auto;
		line-height: 1.4;
		white-space: nowrap;
	}
	
	.form-label .label-badge {
		flex-shrink: 0;
	}
	
	.form-group-content {
		flex: 1;
	}
	
	/* インフォメッセージのPC表示 */
	.info-form-group {
		display: flex;
		align-items: flex-start;
		gap: 24px;
		margin-bottom: 32px;
		padding-bottom: 32px;
	}
	
	.info-label {
		font-size: 15px;
		margin-bottom: 0;
		flex-shrink: 0;
		width: 220px;
		padding-top: 12px;
		display: flex;
		flex-direction: row;
		align-items: flex-start;
		justify-content: flex-start;
	}
	
	.info-label .label-text {
		flex: 0 0 auto;
		line-height: 1.4;
	}
	
	.info-content {
		flex: 1;
		font-size: 14px;
		padding-top: 12px;
		line-height: 1.8;
		text-align: left;
	}
	
	.form-input {
		font-size: 16px;
		padding: 15px 20px;
	}
	
	input[type="text"].form-input:focus,
	input[type="password"].form-input:focus {
		padding: 14px 19px !important;
	}
	
	#loginid:focus {
		padding-right: 67px !important;
	}
	
	.id-dropdown-button {
		width: 40px;
		height: 40px;
		right: 16px;
	}
	
	#loginid {
		padding-right: 68px;
	}
	
	#password {
		width: 100%;
		font-size: 16px;
		padding: 15px 20px;
		border: 2px solid #e0e0e0;
		border-radius: 8px;
		color: #333;
		transition: all 0.3s ease;
		background: #fafafa;
		box-sizing: border-box;
	}
	
	#password:focus {
		outline: none !important;
		border: 3px solid #000000 !important;
		background: #ffffff !important;
		box-shadow: none !important;
		padding: 14px 19px !important;
	}
	
	.form-note {
		font-size: 13px;
		margin-top: 10px;
		text-align: left;
	}
	
	.checkbox-label {
		font-size: 14px;
		margin-top: 14px;
	}
	
	.form-checkbox {
		width: 20px;
		height: 20px;
	}
	
	.login-button {
		padding: 18px 40px;
		font-size: 18px;
	}
	
	.form-submit {
		margin-top: 40px;
		margin-bottom: 20px;
	}
	
	.non-member-button {
		width: 100%;
		padding: 14px 32px;
		font-size: 11px;
	}
	
	.non-member-link {
		margin-bottom: 28px;
	}
	
	.footer-link {
		font-size: 13px;
		margin: 8px 16px;
	}
}

/* スマホ・タブレット (784px以下) */
@media screen and (max-width: 784px) {
	.benesse-header {
		padding: 10px 0;
	}
	
	.benesse-header-inner {
		padding: 0 16px;
	}
	
	.benesse-nav ul {
		gap: 12px;
	}
	
	.benesse-nav a {
		font-size: 12px;
	}
	
	.login-container {
		padding: 24px 16px;
	}
	
	.login-card {
		padding: 24px;
		border-radius: 12px;
	}
	
	.form-group {
		display: block;
	}
	
	.form-label {
		width: auto;
		padding-top: 0;
		margin-bottom: 8px;
	}
	
	/* インフォメッセージのスマホ表示 */
	.info-form-group {
		display: block;
		margin-bottom: 20px;
		padding-bottom: 20px;
	}
	
	.info-label {
		width: auto;
		padding-top: 0;
		margin-bottom: 8px;
		font-size: 13px;
	}
	
	.info-content {
		font-size: 12px;
		padding-top: 0;
		line-height: 1.7;
		text-align: left;
	}
	
	.login-header {
		margin-bottom: 24px;
		padding-bottom: 16px;
	}
	
	.login-title {
		font-size: 24px;
	}
	
	.login-subtitle {
		font-size: 12px;
	}
	
	.form-group {
		margin-bottom: 20px;
	}
	
	.form-label {
		font-size: 13px;
		margin-bottom: 6px;
	}
	
	.label-text {
		margin-right: 4px;
	}
	
	.label-badge {
		font-size: 9px;
		padding: 2px 6px;
	}
	
	.form-input {
		padding: 11px 14px;
		font-size: 14px;
	}
	
	input[type="text"].form-input:focus,
	input[type="password"].form-input:focus {
		padding: 10px 13px !important;
	}
	
	#loginid:focus {
		padding-right: 49px !important;
	}
	
	.id-dropdown-button {
		width: 32px;
		height: 32px;
		right: 10px;
	}
	
	#loginid {
		padding-right: 50px;
	}
	
	#password {
		width: 100%;
		padding: 11px 14px;
		font-size: 14px;
		border: 2px solid #e0e0e0;
		border-radius: 8px;
		color: #333;
		transition: all 0.3s ease;
		background: #fafafa;
		box-sizing: border-box;
	}
	
	#password:focus {
		outline: none !important;
		border: 3px solid #000000 !important;
		background: #ffffff !important;
		box-shadow: none !important;
		padding: 10px 13px !important;
	}
	
	.login-button {
		padding: 13px 20px;
		font-size: 15px;
	}
	
	.form-submit {
		margin-top: 24px;
		margin-bottom: 12px;
	}
	
	.non-member-button {
		width: 100%;
		padding: 11px 20px;
		font-size: 11px;
	}
	
	.non-member-link {
		margin-bottom: 20px;
	}
	
	.form-footer {
		padding-top: 12px;
	}
	
	.footer-link {
		display: block;
		margin: 8px 0;
		font-size: 11px;
	}
	
	.login-footer {
		margin-top: 3px;
		padding-top: 3px;
	}
	
	.login-footer p {
		font-size: 11px;
	}
}

/* アクセシビリティ: フォーカス時のハイライト強化 */
*:focus-visible {
	outline: 3px solid #7c4dff;
	outline-offset: 2px;
}

/* プリント時の調整 */
@media print {
	body {
		background: white;
	}
	
	.login-card {
		box-shadow: none;
		border: 1px solid #ddd;
	}
	
	.form-footer,
	.login-footer {
		display: none;
	}
}

