/**
 * AdminLTE 2 → 4 互換性CSS
 * AdminLTE 2のクラス名をAdminLTE 4のスタイルにマッピング
 * mycom側テンプレートで使用されているAdminLTE 2固有のクラスをサポート
 */

/* ===== レイアウト互換 ===== */
.wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.content-wrapper,
.right-side {
    flex: 1;
    min-height: 100vh;
    background-color: #f4f6f9;
}

.main-footer {
    padding: 1rem;
    background: #fff;
    border-top: 1px solid #dee2e6;
    color: #444;
}

/* ===== ヘッダー互換 ===== */
.main-header {
    position: relative;
    max-height: 100px;
    z-index: 1030;
}

.main-header .logo {
    display: block;
    float: left;
    height: 50px;
    font-size: 20px;
    line-height: 50px;
    text-align: center;
    width: 230px;
    padding: 0 15px;
    font-weight: 300;
    overflow: hidden;
    background-color: #367fa9;
    color: #fff;
}

.main-header .logo em {
    font-style: normal;
}

.main-header .navbar {
    margin-left: 230px;
    min-height: 50px;
    border: none;
    border-radius: 0;
    background-color: #3c8dbc;
}

.main-header .navbar .nav>li>a {
    color: #fff;
}

.main-header .sidebar-toggle {
    float: left;
    background: transparent;
    border: none;
    padding: 15px;
    color: #fff;
    font-size: 1.2rem;
}

/* ===== サイドバー互換 ===== */
.main-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    padding-top: 50px;
    min-height: 100%;
    width: 230px;
    z-index: 810;
    background-color: #222d32;
}

.sidebar {
    padding-bottom: 10px;
}

.sidebar-menu {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sidebar-menu>li {
    position: relative;
    margin: 0;
    padding: 0;
}

.sidebar-menu>li>a {
    padding: 12px 5px 12px 15px;
    display: block;
    color: #b8c7ce;
}

.sidebar-menu>li>a:hover {
    color: #fff;
    background: #1e282c;
}

.sidebar-menu>li>a>.fa,
.sidebar-menu>li>a>i {
    width: 20px;
    text-align: center;
    margin-right: 5px;
}

.sidebar-menu li.header {
    padding: 10px 25px 10px 15px;
    font-size: 12px;
    color: #4b646f;
}

/* skin-blue */
.skin-blue .main-header .navbar {
    background-color: #3c8dbc;
}

.skin-blue .main-header .logo {
    background-color: #367fa9;
}

.skin-blue .main-sidebar {
    background-color: #222d32;
}

.skin-blue .sidebar-menu>li.active>a {
    color: #fff;
    background: #1e282c;
    border-left-color: #3c8dbc;
}

/* ===== コンテンツ互換 ===== */
.content-header {
    position: relative;
    padding: 15px 15px 0 15px;
}

.content-header>h1 {
    margin: 0;
    font-size: 24px;
}

.content {
    min-height: 250px;
    padding: 15px;
}

/* ===== カード互換（box → card） ===== */
.box {
    position: relative;
    border-radius: 0.25rem;
    background: #ffffff;
    border: 0;
    margin-bottom: 1rem;
    box-shadow: 0 0 1px rgba(0, 0, 0, .125), 0 1px 3px rgba(0, 0, 0, .2);
}

.box .box-header {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid rgba(0, 0, 0, .125);
    display: flex;
    align-items: center;
}

.box .box-header .box-title {
    display: inline-block;
    font-size: 1.1rem;
    margin: 0;
    margin-left: 0.5rem;
}

.box .box-header.with-border {
    border-bottom: 1px solid #f4f4f4;
}

.box .box-body {
    padding: 1rem;
}

.box .box-footer {
    padding: 0.75rem 1rem;
    border-top: 1px solid rgba(0, 0, 0, .125);
    background-color: #fff;
}

.box-default {
    border-top: 3px solid #d2d6de;
}

.box-primary {
    border-top: 3px solid #3c8dbc;
}

.box-success {
    border-top: 3px solid #00a65a;
}

.box-warning {
    border-top: 3px solid #f39c12;
}

.box-danger {
    border-top: 3px solid #dd4b39;
}

.box-info {
    border-top: 3px solid #00c0ef;
}

/* ===== タブ互換 ===== */
.nav-tabs-custom {
    margin-bottom: 20px;
    background: #fff;
    box-shadow: 0 1px 1px rgba(0, 0, 0, .1);
    border-radius: 3px;
}

.nav-tabs-custom>.nav-tabs {
    margin: 0;
    border-bottom-color: #f4f4f4;
    border-radius: 3px 3px 0 0;
}

.nav-tabs-custom>.nav-tabs>li {
    margin-bottom: -2px;
    margin-right: 0;
}

.nav-tabs-custom>.nav-tabs>li>a {
    color: #444;
    border-radius: 0;
    border: none;
    padding: 10px 15px;
}

.nav-tabs-custom>.nav-tabs>li.active>a,
.nav-tabs-custom>.nav-tabs>li>a.active {
    border-top: 3px solid #3c8dbc;
    border-bottom: none;
    color: #444;
    background-color: #fff;
}

.nav-tabs-custom>.tab-content {
    padding: 10px;
    border-bottom-right-radius: 3px;
    border-bottom-left-radius: 3px;
}

/* ===== Bootstrap 3 → 5 互換 ===== */
/* grid */
.col-xs-1 {
    flex: 0 0 auto;
    width: 8.333333%;
}

.col-xs-2 {
    flex: 0 0 auto;
    width: 16.666667%;
}

.col-xs-3 {
    flex: 0 0 auto;
    width: 25%;
}

.col-xs-4 {
    flex: 0 0 auto;
    width: 33.333333%;
}

.col-xs-5 {
    flex: 0 0 auto;
    width: 41.666667%;
}

.col-xs-6 {
    flex: 0 0 auto;
    width: 50%;
}

.col-xs-7 {
    flex: 0 0 auto;
    width: 58.333333%;
}

.col-xs-8 {
    flex: 0 0 auto;
    width: 66.666667%;
}

.col-xs-9 {
    flex: 0 0 auto;
    width: 75%;
}

.col-xs-10 {
    flex: 0 0 auto;
    width: 83.333333%;
}

.col-xs-11 {
    flex: 0 0 auto;
    width: 91.666667%;
}

.col-xs-12 {
    flex: 0 0 auto;
    width: 100%;
}

/* float utilities */
.pull-right {
    float: right !important;
}

.pull-left {
    float: left !important;
}

/* visibility */
.hidden-xs {
    display: none !important;
}

@media (min-width: 576px) {
    .hidden-xs {
        display: block !important;
    }
}

.hidden-sm {}

@media (max-width: 767.98px) {
    .hidden-sm {
        display: none !important;
    }
}

/* Glyphicons → Bootstrap Icons mapping */
.glyphicon {
    font-family: "bootstrap-icons" !important;
    font-style: normal;
}

.glyphicon-envelope::before {
    content: "\F32F";
}

.glyphicon-lock::before {
    content: "\F47A";
}

.glyphicon-user::before {
    content: "\F4DA";
}

.glyphicon-search::before {
    content: "\F52A";
}

/* text utilities */
.text-left {
    text-align: left !important;
}

.text-right {
    text-align: right !important;
}

/* margin/padding BS3 compat */
.ml-auto {
    margin-left: auto !important;
}

.mr-auto {
    margin-right: auto !important;
}

/* badge */
.label {
    display: inline-block;
    padding: 0.25em 0.65em;
    font-size: 0.75em;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
    vertical-align: baseline;
    border-radius: 0.25rem;
}

.label-danger {
    background-color: #dc3545;
    color: #fff;
}

.label-warning {
    background-color: #f39c12;
    color: #fff;
}

.label-info {
    background-color: #00c0ef;
    color: #fff;
}

.label-success {
    background-color: #00a65a;
    color: #fff;
}

.label-primary {
    background-color: #3c8dbc;
    color: #fff;
}

/* button */
.btn-flat {
    border-radius: 0;
    box-shadow: none;
}

.btn-block {
    display: block;
    width: 100%;
}

/* img */
.img-circle {
    border-radius: 50% !important;
}

/* input-group BS3 */
.input-group-btn {
    display: flex;
}

/* form-control-feedback for glyphicon icons */
.form-control-feedback {
    position: absolute;
    top: 0;
    right: 0;
    z-index: 2;
    display: block;
    width: 34px;
    height: 34px;
    line-height: 34px;
    text-align: center;
}

.has-feedback .form-control {
    padding-right: 42.5px;
}

.has-feedback {
    position: relative;
}

/* ===== ログインページ互換 ===== */
.login-page {
    display: flex;
    flex-direction: column;
    height: 100vh;
    justify-content: center;
    align-items: center;
    background-color: #d2d6de;
}

.login-box {
    width: 360px;
    margin: 0 auto;
}

.login-logo {
    text-align: center;
    margin-bottom: 25px;
}

.login-logo a {
    color: #444;
    font-size: 35px;
}

.login-logo em {
    font-style: normal;
}

.login-box-body {
    background: #fff;
    padding: 20px;
    border-top: 0;
    color: #666;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .15);
}

.login-box-msg {
    margin: 0;
    padding: 0 20px 20px;
    text-align: center;
}

/* ===== ユーザーメニュー互換 ===== */
.dropdown-menu {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, .175);
    border: 1px solid rgba(0, 0, 0, .15);
}

.user-menu .user-header {
    padding: 10px;
    text-align: center;
}

.user-menu .user-footer {
    padding: 10px;
    border-top: 1px solid #f4f4f4;
    display: flex;
    justify-content: space-between;
}

.user-image {
    float: left;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    margin-right: 10px;
}

.navbar-custom-menu {
    float: right;
}

/* ===== その他 ===== */
.breadcrumb {
    list-style: none;
    display: flex;
    padding: 0;
    margin: 0;
}

.breadcrumb>li+li::before {
    content: ">";
    padding: 0 5px;
    color: #97a0b3;
}

/* sidebar-mini body class */
.sidebar-mini .content-wrapper {
    margin-left: 230px;
}

@media (max-width: 767.98px) {
    .sidebar-mini .content-wrapper {
        margin-left: 0;
    }

    .main-sidebar {
        transform: translateX(-230px);
    }

    .sidebar-open .main-sidebar {
        transform: translateX(0);
    }
}

/* custom icon classes used in mycom */
.icon-memo3,
.icon-layer2,
.icon-mail1,
.icon-clock2,
.icon-send2 {
    display: inline-block;
}

.mr05 {
    margin-right: 5px;
}

.ml05 {
    margin-left: 5px;
}

.ml10 {
    margin-left: 10px;
}

.mb10 {
    margin-bottom: 10px;
}

/* page text and heading overrides */
.page_subhead02 {
    font-size: 18px;
    margin: 10px 0;
    padding-bottom: 5px;
    border-bottom: 1px solid #eee;
}

.page_text {
    padding: 10px 0;
}

.note_text {
    font-size: 12px;
    color: #999;
    margin-top: 5px;
}

/* action link styles */
.list_disc {
    list-style: disc;
    padding-left: 20px;
    margin: 0;
}

.list_disc li {
    margin-bottom: 3px;
}

a.action01,
a.action02,
a.action03,
a.action04,
a.action05,
a.action06,
a.action07,
a.action08 {
    text-decoration: none;
}