/* 一般 */

:root{
    --maxw: 720px;
    --accent: #0a66c2;
    --bg: #f8fbff;
    --card: #ffffff;
}

body {
    font-family: 'Roboto', Arial, sans-serif;
    margin: 0;
    background: #000000;
    font-family: sans-serif;
}

.top-header {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    width: 100%;
    height: 500px; /* お好みで高さ調整 */
    overflow: hidden;

    opacity: 0;                /* 透明に */
    animation: fadeIn 1s forwards;
}

.bg-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover; /* 画面にフィット */
  z-index: 0;
}

.video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* 上は透明 → 下は黒に */
  background: linear-gradient(to bottom, rgba(0,0,0,0) 70%, rgb(0, 0, 0) 100%);
  pointer-events: none; /* クリック操作を邪魔しない */
}

.header-content {
  position: relative;
  z-index: 1; /* 動画の上に表示 */
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding: 0 20px;
  color: white; /* テキストを白にすると見やすい */
  text-shadow: 
    2px 2px 0 black,
   -2px 2px 0 black,
    2px -2px 0 black,
   -2px -2px 0 black;
  text-align: center;
}

.top-header h1 {
    position: relative;
    left: -10px;
    bottom: 0px;
    font-size: 6rem;
    font-family:Cambria, Cochin, Georgia, Times, 'Times New Roman', serif;
    letter-spacing: -2px;
    line-height: 1.1;
    margin: 0;
    z-index: 1;
    text-align: start;

    opacity: 0; /* 非表示から */
    animation: h1FadeInSlow 2s forwards;
    animation-delay: 2s; /* right-imgのアニメ後に開始 */
}

.top-header img {
    position: absolute;
    bottom: 20px;
}

.top-header .left-img {
    left: 100px;
    width: 700px;       /* 左を180pxに */

    transform: translateX(-20%);
    opacity: 0; /* 非表示から */
    animation: fadeInSlow 2s forwards;
    animation-delay: 2s; /* right-imgのアニメ後に開始 */
}

.top-header .right-img {
    right: 0px;
    width: 350px;       /* 右を150pxに */

    transform: translateX(-100%); /* 画面左の外からスタート */
    opacity: 0;
    animation: slideInRight 1s forwards;
    animation-delay: 1s; /* headerが出た後に開始 */
}

/* --- アニメーション定義 --- */
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes slideInRight {
  from { transform: translateX(-100%); opacity: 0; }
  to   { transform: translateX(30%); opacity: 1; }
}

@keyframes fadeInSlow {
  from { transform: translateX(-20%); opacity: 0; }
  to   { transform: translateX(40%); opacity: 0.3; }
}

@keyframes h1FadeInSlow {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* 固定メニュー */
.menu-mark {
  position: absolute;
  top: 50%;
  right: -24px;              /* バナーの外に少し出す */
  transform: translateY(-50%);
  writing-mode: vertical-rl; /* 縦書き */
  color: white;
  font-size: 40px;
  font-weight: bolder;
  letter-spacing: 5px;
  cursor: pointer;
  transition: opacity 0.4s ease;
}

/* 展開中は「…」を消す */
.banner:hover .menu-mark {
  opacity: 0;
}

/* 垂れ幕のデザイン */
.banner {
    z-index: 999; /* ← 前面に表示する */
    position: fixed;
    top: 0;
    left: -215px; 
    width: 240px;
    height: 100%;
    background: rgb(20, 19, 19);
    color: rgb(239, 239, 239);
    padding: 20px 0;
    border: 3px solid white;
    border-radius: 10px;
    transition: left 0.4s ease; 
}

.banner:hover {
    left: 0;
}

.banner h1{
    text-align: center;
    padding-right: 50px;
    padding-top: 20px;
    padding-bottom: 60px;
}

.banner a {
    padding-left: 40px;
    color: rgb(239, 239, 239);
    text-decoration: none;
}

.banner a:hover {
    text-decoration: underline dashed;
}

#home-link {
    padding-left: 20px;
}

.banner a.actual-page {
    color: rgb(142, 189, 224);
    text-decoration:underline;
}

/* 固定Contactリンク */
.fixed-link {
    z-index: 999;
    position: fixed;   /* 画面に固定 */
    top: 10px;         /* 上からの距離 */
    right: 10px;       /* 右からの距離 */
    display: flex;
    flex-direction: column;
    align-items: center;
}

.fixed-link .home {
    background: radial-gradient(
        circle,
        rgba(230, 238, 251, 0.95) 40%,   /* 中心は不透明 */
        rgba(230, 238, 251, 0) 100%  /* 外周で完全に透明 */
    );
    border-radius: 100%;
    padding: 2px;
    padding-bottom: 14px;
    margin-bottom: 10px;
}

.fixed-link .home img {
    width: 100px;
    margin-bottom: 1px;
    margin-left: 1px;
}

.fixed-link .contact {
    background-color: #007bffd0;
    padding: 10px 15px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    color: white;
    text-decoration: none;
    font-weight: bold;
}

.fixed-link .contact:hover {
    background-color: #1265bd;
    text-decoration: underline dashed;
}

.container {
    display: flex;
    justify-content: center; /* 横方向の中央寄せ */
    flex-direction: column;
    margin-left: 20px; /* 垂れ幕の幅分ずらす */
    padding: 20px;
    color: rgb(239, 239, 239);
}

/* コンテンツ定義 */
.content {
    opacity: 0;
    transition: opacity 0.3s;
    margin-top: 30px;
    margin-bottom: 140px;
}

.content.first-content {
    animation: fadeIn 1s forwards;
}

.content.active {
    animation: fadeIn 1s forwards;
}

@keyframes shadowIn {
  from { text-shadow: 0px 0px 0 rgba(165, 165, 165, 0.5); }
  to   { text-shadow: 80px 20px 0 rgb(165, 165, 165, 0.5); }
}

.container h1 {
    text-shadow: 0px 0px 0 rgb(165, 165, 165, 0.5);
    font-size: 60px;
    font-family:'Times New Roman', Times, serif;
    text-align: center;
}

.media-link{
    position: relative;
    display: flex;            /* ← ここが重要 */
    flex-direction: row;
    align-items: center;
    justify-content: center;  /* 横方向の中央寄せ（必要なら flex-start に） */
    gap: 12px;                /* ボタン間の隙間 */    
}

.media-link button{
    display: flex;
    justify-content: center; /* 横方向の中央寄せ */
    align-items: center;
    width: 50px;
    height: 50px;
    background-color: #000000;
    border: 1px solid #e6eefb;
    border-radius: 100%;
    opacity: 1;
    cursor: pointer;   
}

.media-link button img{
    width: 40px;
    height: auto;
}


.media-link button:hover {
    background-color: #2e2e2e;
}


h2{
    font-family:'Times New Roman', Times, serif;
    font-size: 42px;
}

footer {
    display: flex;
    justify-content:space-between;
    flex-direction: row;
    margin-left: 20px; /* 垂れ幕の幅分ずらす */
    margin-right: -40px;
    padding: 20px;
    padding-left: 28%;
    padding-right: 32%;
    color: rgb(239, 239, 239);
    border-top: 1px solid #e6eefb;
    background-color: #1a2632;
    
}

.info {
    font-family:Verdana, Geneva, Tahoma, sans-serif;
}

.info .email {
    margin-left: 20px;
}

.big-spacer {
    margin-bottom: 100px;
}

.representant {
    background-color: #2e2e2e;
    margin-top: 80px;
    margin-left: 16%;
    margin-right: 16%;
    border: 8px double #e6eefb;
    border-radius: 10px;
    display: flex;
    align-items: center;
}

.representant-title {
    display: none;
}

.representant img {
    margin-left: 50px;
    margin-right: 0px;
    width: 40%;
    height: 100%;
    border-radius: 5px;
}

.representant .description {
    position: relative;
    margin-left: 50px;
    padding-bottom: 30px;
}

.representant .description + img {
    margin-left: 50px;
    margin-right: 50px;
}

.bg-image {
    position: fixed;
    top: 10%;
    width: 400px;
    opacity: 0;             /* 初期は非表示 */
    border-radius: 4px;
    filter: blur(2px);
    z-index: -1;
}

.bg-image.left {
    left: 50px;
    animation: leftAnim 4s forwards;  /* 左画像のループ */
}

.bg-image.right {
    right: 50px;
    animation: rightAnim 4s forwards; /* 右画像のループ */
}

/* 右画像のアニメーション */
@keyframes rightAnim {
    0%   { opacity: 0; transform: translateX(0); }
    75%  { opacity: 0.7; transform: translateX(10px); }
    85%  { opacity: 0.7; transform: translateX(10px); }
    100%  { opacity: 0; transform: translateX(10px); }
}

/* 左画像のアニメーション */
@keyframes leftAnim {
    0%   { opacity: 0; transform: translateX(0); }
    75%  { opacity: 0.7; transform: translateX(-10px); }
    85%  { opacity: 0.7; transform: translateX(-10px); }
    100%  { opacity: 0; transform: translateX(-10px); }
}


.history {
  position: relative;
  margin: 40px auto;
  margin-left: 23%;
  margin-right: 23%;
  margin-top: 40px;
  padding-left: 40px;       /* 左に余白を作って線を描く */
  border-left: 3px solid #ffffff; /* タイムラインの縦線 */
  width: 60%;
  font-family: sans-serif;
}

.timeline-item {
  margin: 40px 0;
  position: relative;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: -20px;
  top: 10%;
  width: 15px;
  height: 15px;
  background: #fff;
  border: 3px solid #333;
  border-radius: 50%;   /* 丸いノード */
}

.year {
  font-weight: bold;
  font-size: 30px;
  margin-bottom: 5px;
}

.event {
  margin-left: 10px;
  margin-bottom: 20px;
  padding-left: 1em;   /* 全体を右に寄せる */
  text-indent: -1em;   /* 1行目だけ左に戻す */
}

.event::before  {
  content: "・";
  position: relative;
  right: 5px;
  top: 5px;
  font-size: 24px;
}


@media screen and (max-width: 1024px) {
    @keyframes slideInRight {
        from { transform: translateX(-100%); opacity: 0; }
        to   { transform: translateX(100%); opacity: 1; }
    }

    @keyframes fadeInSlow {
        from { transform: translateX(-20%); opacity: 0; }
        to   { transform: translateX(25%); opacity: 0.3; }
    }

    .representant {
        margin-left: 7%;
        margin-right: 7%;
    }

    .history {
        margin-left: 20%;
        margin-right: 20%;
    }
}


@media screen and (max-width: 768px) {
    @keyframes slideInRight {
        from { transform: translateX(-100%); opacity: 0; }
        to   { transform: translateX(80%); opacity: 1; }
    }

    @keyframes fadeInSlow {
        from { transform: translateX(-20%); opacity: 0; }
        to   { transform: translateX(20%); opacity: 0.3; }
    }

    .description h2 {
        display: none;
    }

    .history {
        margin-left: 15%;
        margin-right: 15%;
    }

    .representant {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .representant-title {
        display: block;
    }

    .representant .description {
        margin-left: 10px;
        margin-right: 0px;
        order: 2;
        text-align: left;
    }

    .description h2 {
        display: none;
    }

    .representant img {
        margin-left: 0px;
        margin-right: 0px;
        width: 80%;
        order: 1;
    }
}


@media screen and (max-width: 700px) {
    @keyframes slideInRight {
        from { transform: translateX(-100%); opacity: 0; }
        to   { transform: translateX(60%); opacity: 1; }
    }

    @keyframes fadeInSlow {
        from { transform: translateX(-20%); opacity: 0; }
        to   { transform: translateX(-8%); opacity: 0.3; }
    }

    .container {
        margin-left: 50px;
        padding: 0px;
    }

    .container h1 {
        font-size: 45px;
    }

    h2 {
        font-size: 30px;
    }

    p {
        font-size: 16px;
    }

    @keyframes shadowIn {
        from { text-shadow: 0px 0px 0 rgba(165, 165, 165, 0.5); }
        to   { text-shadow: 40px 10px 0 rgb(165, 165, 165, 0.5); }
    }

    .info {
        display: none;
    }

    .media-link {
        margin-left: 20px;
    }

    .fixed-link {
        top: 5px;
        right: 5px;
    }

    .fixed-link .home {
        padding-bottom: 7px;
        margin-bottom: 10px;
    }

    .fixed-link .home img {
        width: 60px;
    }

    .fixed-link .contact {
        background-color: #007bff6e;
        padding: 5px 10px;
        font-size: 10px;
    }

    .history {
        margin-left: 10%;
        margin-right: 10%;
    }

    .timeline-item {
        margin: 30px 0;
    }

    .timeline-item::before {
    left: -20px;
    top: 10px;
    width: 10px;
    height: 10px;
    }

    .year {
        font-size: 20px;
    }

    .event {
        margin-left: 4px;
        font-size: 16px;
    }

    .representant {
        margin-left: 0%;
        margin-right: 0%;
    }
}