/* /front/css/shell.css */

/* --- 管理ページからカラーテーマをインポート --- */
:root {
	--primary-color: #5A8B7B;
	--background-color: #F8F8F4;
	--shell-bg: #BCA694; /* ヘッダー・フッター背景 */
	--shell-text: #5C4F47;
	--border-color: #e0e0e0;
	--text-color: #3E3E3E;
}

*, *::before, *::after {
    box-sizing: border-box;
}

/* --- 基本レイアウト --- */
body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--background-color);
}
.app-shell {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* --- ヘッダー --- */
.shell-header {
	position: fixed;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.8);
    color: var(--shell-text);
    flex-shrink: 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.shell-header .shell-title {
	vertical-align: middle;
    background-color: var(--shell-bg);
    color: #FDFCFA;
}
.shell-title h1 {
	font-size: 0.8em;
	line-height: 1.4em;
    max-width: 1200px;
    margin: 0 auto;
	font-weight: normal;
}
.shell-header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}
.shell-logo a {
    font-size: 1.5em;
    font-weight: bold;
    text-decoration: none;
}
.shell-nav a, #welcom-nav a {
    color: var(--shell-text);
    margin: 0 1rem;
    text-decoration: none;
    font-weight: 500;
    transition: opacity 0.2s;
}
#welcom-nav a {
	color: var(--primary-color);
	font-size: 1em;
}

.shell-nav a:hover, #welcom-nav a:hover {
    opacity: 0.8;
}


/* --- メインボディ (コンテンツ + サイドバー) --- */
.app-body {
    display: flex;
    flex-grow: 1;
    max-width: 1200px;
    width: 100%;
    margin: 15px auto;
    gap: 1.5rem;
	margin-top: 100px;
}
main {
    flex-grow: 1;
/*    background-color: #fff; */
    border-radius: 8px;
/*    border: 1px solid var(--border-color);*/
    overflow: hidden; /* iframeの角丸を適用 */
	transition: height 0.2s ease-out;
}
#content-frame {
    width: 100%;
    height: 100%;
    border: none;
	display: block;
}
.shell-sidebar {
    width: 280px;
    flex-shrink: 0;
}
.sidebar-widget {
    background-color: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1.5rem;
}
.sidebar-widget h3 {
    margin-top: 0;
    font-size: 1.1em;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.5rem;
}
.sidebar-widget ul {
	padding-inline-start: 1.5em;
}
/* --- フッター --- */
.shell-footer {
    background-color: var(--shell-bg);
    color: var(--shell-text);
    padding: 1.5rem 2rem;
    flex-shrink: 0;
    font-size: 0.85em;
}
.shell-footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}
.footer-links span {
	white-space: nowrap;
}
.footer-links a {
    color: var(--shell-text);
    margin-left: 1.5rem;
}
.sidebar-widget h3 {
    padding-bottom: 0.3rem;
    text-align: center;
    margin-bottom: 15px; /* ボタンとの余白を確保 */
}

/* サイドバーウィジェット内のボタン共通スタイル */
.sidebar-widget .btn {
    display: block;
    width: 100%;
    text-align: center;
    margin-right: 0; /* 共通のbtnクラスにある右マージンをリセット */
}

/* ログインボタンと会員登録ボタンの間の余白 */
.btn {
    padding: 10px 15px!important;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    text-decoration: none;
    color: white;
    font-size: 0.9em!important;
    display: inline-block;
    margin-right: 5px;
}
.btn-primary {
    background-color: var(--primary-color)!important;
}
.btn-secondary {
    background-color: #7f8c8d!important;
}
.sidebar-widget .btn + .btn {
    margin-top: 10px;
}
#welcom-nav {
	display: none;
    text-align: center;
    font-size: 0.8em;
}
#welcom-nav .btn {
	color: #fff;
	padding: 5px 10px!important;
	font-size: 1em!important;
}
/* ===== サイドバー 広告・お知らせ ===== */
.sidebar-widget .promotion-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.sidebar-widget .promotion-list li {
    margin-bottom: 10px;
}
.sidebar-widget .promotion-list li:last-child {
    margin-bottom: 0;
}
.sidebar-widget .promotion-list img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 4px;
}
.sidebar-widget .promotion-list.text-list .date {
    font-size: 0.8em;
    color: #6c757d;
    display: block;
}
.sidebar-widget .promotion-list.text-list p {
    font-size: 0.9em;
    margin: 2px 0 0;
    line-height: 1.5;
}
/* --- レスポンシブ対応 --- */
@media (max-width: 992px) {
    .app-body {
        flex-direction: column; /* サイドバーを下に */
        margin-top: 140px;
    }
    .shell-sidebar {
        width: 100%;
    }
    .shell-header h1 {
        padding-left: 1em;
    }
}
@media (max-width: 768px) {
    .shell-header-content {
        flex-direction: column;
        height: auto;
        padding: 0.75rem 0;
    }
    .shell-footer-content {
        flex-direction: column;
        gap: 0.5rem;
    }
	.shell-logo {
		display: flex;
	    align-items: center;
    	gap: 2em;
	}
	.sidebar-widget.welcom {
		display: none;
	}
	#welcom-nav {
		display: flex;
		flex-direction: column;		
	}
}