@charset "utf-8";

/* ==================================================
   1. リセット & 基本スタイル (Reset & Base)
================================================== */
* {
   box-sizing: border-box;
   margin: 0;
   padding: 0;
}

html {
   overflow-y: scroll;
}

html, body {
   height: 100%;
   background-color: #f5f3ef;
   color: #333333;
   font-family: "メイリオ", Meiryo, "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", Osaka, "ＭＳ Ｐゴシック", sans-serif;
   font-size: 14px;
   line-height: 1.6;
}

img {
   max-width: 100%;
   height: auto;
   vertical-align: middle;
   border: none;
}

a {
   color: #900000;
   text-decoration: none;
   transition: color 0.2s ease, opacity 0.2s ease;
}

a:hover {
   color: #e60000;
   text-decoration: underline;
}

ul, ol {
   list-style: none;
}


/* ==================================================
   2. 全体レイアウト構造 (Layout Structure)
================================================== */
#top {
   width: 100%;
   max-width: 960px;
   margin: 0 auto;
   background-color: #ffffff;
   box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
   min-height: 100vh;
   display: flex;
   flex-direction: column;
   overflow: hidden;
}

#headWrap {
   width: 100%;
   background-color: #ffffff;
   border-bottom: 3px solid #900000;
}

#header {
   display: flex;
   justify-content: space-between;
   align-items: center;
   padding: 15px 20px;
   position: relative;
}

#header h1 {
   margin: 0;
   line-height: 1;
}

#header h1 img {
   max-height: 50px;
}

#pr {
   font-size: 12px;
   color: #666666;
}

#icatch {
   width: 100%;
   overflow: hidden;
}

#icatch img {
   width: 100%;
   max-width: 100%;
   height: auto;
   display: block;
}


/* ==================================================
   3. グローバルナビゲーション (Global Menu)
================================================== */
#menu {
   width: 100%;
   background-color: #900000;
   position: relative;
}

#menu ul {
   display: flex;
   flex-wrap: wrap;
   margin: 0;
   padding: 0;
}

#menu li {
   flex: 1 1 0;
   text-align: center;
   border-right: 1px solid rgba(255, 255, 255, 0.2);
}

#menu li:last-child {
   border-right: none;
}

#menu li a {
   display: block;
   padding: 13px 5px; /* 上下のパディングを12pxから18pxに変更して高さを延長 */
   color: #ffffff;
   font-weight: bold;
   font-size: 15px; /* 文字サイズを14pxから16pxに変更して拡大 */
   text-decoration: none;
   white-space: nowrap;
}

#menu li a:hover {
   background-color: #700000;
   text-decoration: none;
}

/* ハンバーガーボタン（PC時は非表示） */
.menu-toggle {
   display: none;
   flex-direction: column;
   justify-content: space-between;
   width: 30px;
   height: 22px;
   background: transparent;
   border: none;
   cursor: pointer;
   padding: 0;
   z-index: 101;
}

.menu-toggle span {
   width: 100%;
   height: 3px;
   background-color: #333333;
   transition: all 0.3s ease;
}

/* ハンバーガーボタンが開いた時のアニメーション */
.menu-toggle.active span:nth-child(1) {
   transform: translateY(9.5px) rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
   opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
   transform: translateY(-9.5px) rotate(-45deg);
}


/* ==================================================
   4. コンテンツ領域 & パンくずリスト (Contents & Breadcrumbs)
================================================== */
#contents {
   display: block;
   padding: 20px;
   flex: 1 0 auto;
   width: 100%;
   box-sizing: border-box;
}

#topicPath {
   width: 100%;
   font-size: 12px;
   color: #666666;
   margin-top: 0 !important;
   margin-bottom: 15px !important;
   padding-bottom: 8px;
   border-bottom: 1px dotted #ccc;
   line-height: 1.2;
}

#topicPath a {
   color: #666666;
}

#contents::after {
   content: "";
   display: table;
   clear: both;
}

#sub {
   float: left;
   width: 200px;
   margin-top: 0 !important;
   padding-top: 0 !important;
}

#main {
   float: right;
   width: 690px;
   margin-top: 0 !important;
   padding-top: 0 !important;
}


/* ==================================================
   5. #main 内 見出しデザイン
================================================== */
#main h3 {
   font-size: 18px;
   font-weight: bold;
   color: #1a1a1a;
   padding: 10px 15px;
   margin-top: 35px;
   margin-bottom: 15px;
   background-color: #fbf2f2;
   border-left: 7px solid #900000;
   border-bottom: 2px solid #e0d0d0;
   border-radius: 0 4px 4px 0;
   line-height: 1.4;
   letter-spacing: 0.05em;
}

#main h3:first-child {
   margin-top: 0 !important;
}

#main p {
   margin-top: 0;
   margin-bottom: 22px;
   line-height: 1.7;
   color: #333333;
   font-size: 14px;
}

#main strong, 
#main b,
#main em {
   background: linear-gradient(transparent 60%, #fff099 60%);
   font-weight: bold;
   color: #111111;
   padding: 0 2px;
}


/* ==================================================
   6. サイドバー & アコーディオンナビ
================================================== */
#sub .section {
   margin-bottom: 25px;
   background-color: #faf9f6;
   border: 1px solid #e5e0d8;
   border-radius: 4px;
   overflow: hidden;
}

#sub .section:first-child,
#sub .main-courses {
   margin-top: 0 !important;
   padding-top: 0 !important;
}

#sub h2 {
   font-size: 15px;
   color: #ffffff;
   background-color: #900000;
   padding: 10px 15px;
   margin: 0 !important;
}

#sub ul {
   padding: 0;
   margin: 0;
}

#sub li {
   border-bottom: 1px solid #e5e0d8;
}

#sub li:last-child {
   border-bottom: none;
}

#sub li a {
   display: block;
   padding: 10px 15px;
   color: #333333;
   font-size: 13px;
   text-decoration: none;
}

#sub li a:hover {
   background-color: #f0eae1;
   color: #900000;
}

.has-accordion {
   position: relative;
}

.accordion-toggle {
   display: flex !important;
   justify-content: space-between;
   align-items: center;
   cursor: pointer;
   font-weight: bold;
   background-color: #f4efe6;
}

.accordion-toggle .arrow {
   font-size: 10px;
   transition: transform 0.3s ease;
   color: #777777;
}

.has-accordion.is-open .accordion-toggle .arrow {
   transform: rotate(180deg);
}

.accordion-menu {
   display: none;
   background-color: #ffffff;
}

.accordion-menu li {
   border-bottom: 1px dashed #eee;
}

.accordion-menu li:last-child {
   border-bottom: none;
}

.accordion-menu li a {
   padding-left: 25px !important;
   font-weight: normal;
   font-size: 12px;
   color: #555555;
}

.accordion-menu li a:before {
   content: "・";
   margin-right: 4px;
   color: #900000;
}

#sub .sub-info li a {
   font-weight: bold;
   background-color: #f4efe6;
}


/* ==================================================
   7. テーブル共通デザイン
================================================== */
#main table,
table {
   width: 100%;
   table-layout: fixed;
   border-collapse: collapse;
   margin-top: 15px;
   margin-bottom: 25px;
   background-color: #ffffff !important;
   background-image: none !important;
   border: 1px solid #cccccc;
}

#main table th,
table th {
   background-color: #900000 !important;
   background-image: none !important;
   color: #ffffff !important;
   padding: 10px;
   font-weight: bold;
   text-align: center;
   border: 1px solid #730000;
   vertical-align: middle;
}

#main table tbody th,
table tbody th {
   background-color: #f4f4f4 !important;
   background-image: none !important;
   color: #333333 !important;
   border: 1px solid #cccccc;
   font-weight: bold;
   text-align: center;
}

#main table td,
table td {
   background-color: #ffffff !important;
   background-image: none !important;
   padding: 10px;
   border: 1px solid #cccccc;
   color: #333333;
   line-height: 1.5;
   vertical-align: middle;
   word-break: break-all;
}

.schedule-table,
.fee-table {
   width: 100%;
   border-collapse: collapse;
   margin: 15px 0 10px 0;
}

.schedule-table th,
.fee-table th {
   background-color: #900000 !important;
   color: #ffffff !important;
   padding: 8px 10px;
   font-size: 13px;
   text-align: center;
}

.schedule-table td {
   padding: 10px 12px !important;
   vertical-align: middle;
}

.fee-table td {
   padding: 5px 10px !important;
   vertical-align: middle;
}

.subject-list {
   list-style: none;
   padding: 0;
   margin: 0;
}

.subject-list li {
   position: relative;
   padding-left: 14px;
   line-height: 1.4;
   font-size: 13px;
   margin-bottom: 2px;
}

.subject-list li:last-child {
   margin-bottom: 0;
}

.subject-list li::before {
   content: "•";
   color: #900000;
   font-weight: bold;
   position: absolute;
   left: 0;
}

.fee-table tr:nth-child(even) td {
   background-color: #fafafa !important;
}

.fee-item-box {
   display: flex;
   justify-content: space-between;
   align-items: center;
   width: 100%;
   padding: 0 5px;
}

.grade-label {
   font-weight: bold;
   color: #333333;
   font-size: 13px;
}

.price-text {
   font-size: 14px;
   font-weight: bold;
   color: #900000;
   letter-spacing: 0.03em;
}

.fee-note {
   margin-top: 8px;
   padding: 6px 10px;
   background-color: #f2f2f2;
   border-radius: 4px;
   font-size: 11px;
   color: #555555;
   line-height: 1.4;
}

.date-cell {
   text-align: center;
   background-color: #fafafa !important;
   vertical-align: middle;
   padding: 12px 8px !important;
}

.year-text {
   display: block;
   font-size: 11px;
   color: #666666;
   margin-bottom: 2px;
}

.date-highlight {
   display: block;
   color: #900000;
   font-size: 15px;
   font-weight: bold;
   line-height: 1.3;
}

.status-cell {
   text-align: center;
   background-color: #fffaf8 !important;
   vertical-align: middle;
   padding: 14px 8px !important;
   border-left: 2px solid #e0b0b0 !important;
}

.status-badge {
   display: inline-block;
   background-color: #900000;
   color: #ffffff;
   font-size: 11px;
   font-weight: bold;
   padding: 2px 10px;
   border-radius: 12px;
   margin-bottom: 8px;
}

.deadline-text {
   display: block;
   font-size: 14px;
   color: #111111;
   margin-top: 2px;
}

.deadline-text strong {
   color: #900000;
   font-size: 15px;
   background: none !important;
}

.schedule-notice {
   background-color: #f9f8f6;
   border: 1px solid #e5e0d8;
   border-radius: 4px;
   padding: 12px 15px;
   margin-bottom: 30px;
   font-size: 13px;
   line-height: 1.7;
}

.schedule-notice p {
   margin: 0 !important;
}

.schedule-notice a {
   font-weight: bold;
   text-decoration: underline;
}


/* ==================================================
   8. 問い合わせフォーム & 案内エリア
================================================== */
.mail-form {
   margin-top: 15px;
}

.form-table {
   width: 100%;
   table-layout: fixed;
   margin-bottom: 20px;
}

.form-table th {
   width: 30%;
   background-color: #f4f4f4 !important;
   color: #333333 !important;
   text-align: right !important;
   padding: 12px 10px !important;
   border: 1px solid #cccccc !important;
}

.form-table td {
   width: 70%;
   background-color: #ffffff !important;
   padding: 10px !important;
   border: 1px solid #cccccc !important;
   word-break: break-all;
}

.form-table input[type="text"],
.form-table input[type="email"],
.form-table textarea {
   width: 100%;
   padding: 8px 10px;
   border: 1px solid #ccc;
   border-radius: 4px;
   font-size: 14px;
   font-family: inherit;
}

.form-table input[type="text"]:focus,
.form-table input[type="email"]:focus,
.form-table textarea:focus {
   border-color: #900000;
   outline: none;
   background-color: #ffffff;
}

.form-btn input[type="submit"],
.form-btn input[type="button"] {
   background-color: #900000;
   color: #ffffff;
   border: none;
   padding: 10px 30px;
   border-radius: 4px;
   cursor: pointer;
   font-weight: bold;
   margin: 0 5px;
}

.contact-info-box {
   max-width: 480px;
   margin: 20px 0 25px 0;
   padding: 18px 20px;
   background: linear-gradient(135deg, #fff8f8 0%, #fdf2f2 100%);
   border: 1px solid #ebd0d0;
   border-left: 5px solid #900000;
   border-radius: 8px;
   box-shadow: 0 4px 12px rgba(144, 0, 0, 0.06);
   display: flex;
   flex-direction: column;
   gap: 10px;
   text-align: left;
}

.contact-info-box p {
   margin-bottom: 6px !important;
   line-height: 1.4 !important;
   font-size: 14px;
}

.contact-info-box p:last-child {
   margin-bottom: 0 !important;
}

.contact-card {
   background-color: #ffffff;
   border: 1px solid #e8d7d7;
   border-radius: 6px;
   padding: 12px 18px;
   display: flex;
   align-items: center;
   justify-content: space-between;
   box-shadow: 0 2px 5px rgba(0, 0, 0, 0.03);
   transition: all 0.25s ease;
}

.contact-card:hover {
   background-color: #ffffff;
   border-color: #900000;
   transform: translateY(-2px);
   box-shadow: 0 4px 10px rgba(144, 0, 0, 0.12);
}

.contact-title {
   display: flex;
   align-items: center;
   gap: 12px;
   font-weight: bold;
   font-size: 14px;
   color: #333333;
}

.contact-tag {
   font-size: 11px;
   font-weight: bold;
   color: #ffffff;
   background-color: #900000;
   padding: 3px 8px;
   border-radius: 4px;
   letter-spacing: 0.05em;
   min-width: 46px;
   text-align: center;
}

.contact-action {
   text-align: right;
   display: flex;
   align-items: center;
   justify-content: flex-end;
}

.contact-action-link {
   display: inline-flex;
   align-items: center;
   gap: 6px;
   font-weight: bold;
   font-size: 13px;
   color: #900000 !important;
   text-decoration: none !important;
   padding: 4px 10px;
   border-radius: 4px;
   transition: background-color 0.2s ease, color 0.2s ease;
}

.contact-action-link:hover {
   background-color: #f7e6e6;
   color: #900000 !important;
}

.contact-action-link::after {
   content: "➔";
   font-size: 11px;
   color: #900000;
   transition: transform 0.2s ease;
}

.contact-action-link:hover::after {
   transform: translateX(3px);
}

.contact-phone-text {
   display: inline-flex;
   align-items: center;
   font-weight: bold;
   font-size: 14px;
   color: #900000;
   padding: 4px 10px;
   letter-spacing: 0.03em;
}


/* ==================================================
   9. 「検定試験について」のデザイン調整
================================================== */
.kentei-about-list {
   display: flex;
   flex-direction: column;
   gap: 16px;
   margin-top: 15px;
   margin-bottom: 30px;
}

.kentei-about-list dt {
   font-weight: bold;
   font-size: 13px;
   color: #444444;
   background-color: #f0f0f0;
   border: 1px solid #e0e0e0;
   padding: 4px 12px;
   border-radius: 4px;
   display: inline-block;
   align-self: flex-start;
   margin-bottom: 0;
}

.kentei-about-list dd {
   padding: 0 8px 0 12px;
   margin: 0;
   font-size: 13px;
   line-height: 1.6;
   color: #333333;
}


/* ==================================================
   10. 「検定試験の申込方法」専用デザイン
================================================== */
#apply {
   margin-top: 35px;
}

.apply-card-container {
   display: flex;
   flex-direction: column;
   gap: 20px;
   margin-top: 15px;
   margin-bottom: 30px;
}

.apply-card {
   background-color: #ffffff;
   border: 1px solid #e0e0e0;
   border-radius: 6px;
   padding: 20px;
   box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.apply-card-title {
   font-size: 15px;
   font-weight: bold;
   color: #900000;
   padding-bottom: 8px;
   margin-bottom: 12px;
   border-bottom: 2px solid #f7e6e6;
   display: flex;
   align-items: center;
   gap: 8px;
}

.apply-card-content p {
   margin-bottom: 12px !important;
   font-size: 13px;
   line-height: 1.6;
}

.apply-card-content p:last-child {
   margin-bottom: 0 !important;
}

.apply-step-list {
   display: flex;
   flex-direction: column;
   gap: 16px;
   margin-top: 12px;
}

.apply-step-item {
   background-color: #fafafa;
   border: 1px solid #eeeeee;
   border-radius: 4px;
   padding: 12px 15px;
}

.apply-step-header {
   font-weight: bold;
   font-size: 13px;
   color: #333333;
   margin-bottom: 8px;
   display: flex;
   align-items: center;
   gap: 8px;
}

.step-num {
   background-color: #900000;
   color: #ffffff;
   font-size: 11px;
   padding: 2px 8px;
   border-radius: 3px;
}

.memo-box {
   background-color: #ffffff;
   border: 1px dashed #cccccc;
   border-radius: 4px;
   padding: 12px 15px;
   margin: 10px 0;
   font-size: 13px;
}

.memo-box-title {
   font-weight: bold;
   color: #555555;
   margin-bottom: 6px;
   font-size: 12px;
}

.memo-box ol {
   padding-left: 20px;
   margin: 0;
}

.memo-box li {
   list-style-type: decimal;
   margin-bottom: 4px;
   color: #444444;
}

.download-links {
   display: flex;
   flex-wrap: wrap;
   gap: 10px;
   margin-top: 10px;
}

.btn-download {
   display: inline-flex;
   align-items: center;
   gap: 6px;
   background-color: #f0f0f0;
   color: #333333 !important;
   font-size: 12px;
   font-weight: bold;
   padding: 6px 12px;
   border: 1px solid #ccc;
   border-radius: 4px;
   text-decoration: none !important;
   transition: all 0.2s ease;
}

.btn-download:hover {
   background-color: #e2e2e2;
   border-color: #999999;
}

.address-box {
   background-color: #fcfcfc;
   border-left: 4px solid #900000;
   padding: 10px 15px;
   margin-top: 8px;
   font-size: 13px;
   line-height: 1.6;
}

.apply-warning-card {
   background-color: #fff9f9;
   border: 1px solid #f2c7c7;
   border-radius: 6px;
   padding: 16px 20px;
}

.apply-warning-title {
   font-size: 14px;
   font-weight: bold;
   color: #c00000;
   margin-bottom: 10px;
   display: flex;
   align-items: center;
   gap: 6px;
}

.apply-warning-list {
   list-style: disc;
   padding-left: 18px;
   margin: 0;
}

.apply-warning-list li {
   font-size: 13px;
   color: #444444;
   margin-bottom: 8px;
   line-height: 1.5;
}

.apply-warning-list li:last-child {
   margin-bottom: 0;
}


/* ==================================================
   11. 固有要素 & ページトップ
================================================== */
#pageTop {
   text-align: right;
   margin-top: 20px;
   margin-bottom: 10px;
   width: 100%;
}

#pageTop a {
   font-size: 12px;
   color: #666666;
}

#footer {
   width: 100%;
   background-color: #333333;
   color: #ffffff;
   margin-top: auto;
}

#footMenu {
   padding: 15px;
   border-bottom: 1px solid #444444;
}

#footMenu ul {
   display: flex;
   justify-content: center;
   flex-wrap: wrap;
   gap: 15px;
}

#footMenu a {
   color: #cccccc;
   font-size: 12px;
}

#footMenu a:hover {
   color: #ffffff;
}

.copyright {
   text-align: center;
   font-size: 11px;
   color: #999999;
   padding: 15px;
}


/* ==================================================
   12. レスポンシブ対応 (768px以下)
================================================== */
@media screen and (max-width: 768px) {
   #header {
      display: flex;
      flex-direction: row;
      justify-content: space-between;
      align-items: center;
      text-align: left;
      gap: 10px;
      padding: 12px 15px;
      position: relative;
   }

   #header h1 img {
      max-height: 38px; 
   }

   .menu-toggle {
      display: flex !important;
      position: static; 
      top: auto;
      right: auto;
      z-index: 9999;
   }

   #menu {
      position: relative;
   }

   #menu ul {
      display: none;
      flex-direction: column;
      background-color: #900000;
      position: absolute;
      top: 100%;
      left: 0;
      width: 100%;
      z-index: 1000;
      box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
   }

   #menu ul.is-open {
      display: flex !important;
   }

   #menu li {
      width: 100%;
      border-right: none;
      border-bottom: 1px solid rgba(255, 255, 255, 0.1);
   }

   #menu li a {
      padding: 12px 20px;
      font-size: 14px;
      text-align: left;
   }

   #contents {
      padding: 15px;
   }

   #sub, #main {
      float: none;
      width: 100%;
   }

   /* スマホ時かつ sub-hidden-sp が付与されている場合、サイドバーを非表示にする */
   #sub.sub-hidden-sp {
      display: none !important;
   }

   .form-table th, 
   .form-table td {
      display: block;
      width: 100% !important;
      text-align: left !important;
   }

   .form-table th {
      border-bottom: none !important;
   }

   .contact-info-box {
      max-width: 100%;
   }

   .contact-card {
      flex-direction: column;
      align-items: flex-start;
      gap: 8px;
   }

   .contact-action {
      text-align: left;
      width: 100%;
      justify-content: flex-start;
   }

   /* ▼ スマホ時のフッターメニューの折り返し・配置調整 ▼ */
   #footMenu ul {
      display: flex !important;
      flex-wrap: wrap !important;
      justify-content: center !important;
      gap: 8px 12px !important;
   }

   #footMenu li {
      flex: 0 1 auto !important;
      text-align: center;
      margin: 0 !important;
   }

   #footMenu li a {
      display: inline-block;
      padding: 6px 10px;
      font-size: 13px;
      background-color: rgba(255, 255, 255, 0.05);
      border-radius: 4px;
   }
}