@charset "UTF-8";

:root {
    --beige: #fafbe6;
    --white: #fcfcef;
    --skyblue: #98d2c0;
    --emeraldgreen: #03aa9d;
    --navy: #215881;
}

body{
   background-color: var(--beige);
   font-family: Zen Kaku Gothic New;
}

.container {
    width: 100%;
    max-width: 450px; 
    box-sizing: border-box;
    margin: 40px auto;
}

.tab {
    display: flex;            
    margin: 0 auto;         
    width: 100%;
    padding: 0;               
    list-style: none;
    font-weight: 400;
    font-size: 16px;
    color: var(--navy);
    margin-bottom: 20px;
}

.tab li {
    flex: 1;                  
    text-align: center;       
    display: flex;           
}

.tab li a {
    display: flex;            
    align-items: center;      
    justify-content: center;  
    height: 100%;             
    box-sizing: border-box;  
    width: 100%;
    position: relative;       
    background-color: #e6e6e6;
    color: #000000;           
    cursor: pointer;          
    transition: 0.3s all;     
    text-decoration: none;
    padding: 0.7em 0.5em;     
    border-top: solid 2px var(--navy);
    border-bottom: solid 2px var(--navy);
    border-right: solid 2px var(--navy);
    border-left: none;       
}

.tab li:first-child a {
    border-left: solid 2px var(--navy);
}

.tab li a.active {
    background-color: var(--emeraldgreen); 
    color: var(--beige);           
    font-weight: normal;
    border-top: solid 2px var(--navy);
    border-bottom: solid 2px var(--navy);
    border-right: solid 2px var(--navy);
}

.box{
    margin-left: 20px;
    margin-right: 20px;
    border:1px solid var(--emeraldgreen);
    background-color: var(--white);
    position:relative;
    justify-content:center;
    padding:15px;
    line-height:1.5;
    font-size:16px;
    text-align:justify;
    text-align-last:left;
    margin-top:30px;
    margin-bottom: 30px;
}

.area {
	display: none;
	opacity: 0;
    position:relative;
}

.area.is-active {
    display: block;
    animation-name: displayAnime;/*ふわっと表示させるためのアニメーション*/
    animation-duration: 2s;
    animation-fill-mode: forwards;    
}

@keyframes displayAnime{
	from {
		opacity: 0;
	}
	to {
		opacity: 1;
	}
}

@media (min-width: 1024px) {
.container { flex-direction: row; } /* PC :横並び */
.tab{
    width:100vw;
    height: 55px;
    margin-left: calc(50% - 50vw);
    font-size: 18px;
}
.box{
    width:60vw;
    margin-left: calc(50% - 30vw); 
    font-size: 17px;
}
}



/*
css概説（復習用　要らなければ消してください）

vol.1 用語の解説

セレクタ…装飾をつけたい対象の要素のこと
属性…セレクタに施したい装飾の種類
値…セレクタに施したい装飾の具体的内容

例：h1{color:red;}
h1がセレクタ　colorが属性　redが値

vol.2 セレクタの指定
①要素名で指定
h1{color:red;}

②class名で指定
.class{color:red;}

③id名で指定
#id{color:red;}

④要素名プラスclass名で指定
div.class{color:red;}

⑤要素名プラスid名で指定
div#id{color:red;}

⑥要素の位置から指定
header div{color:red;}   
↑スペースを入れる（ここではheader内のdiv要素を指定）

vol.3 属性・値の指定

①{属性:値;}の形で記述
{color:red;}

②１つのセレクタに対する指定はまとめて記述できる
h1{
   color:red;
   width:90%;
}

③指定が重複したら後の行にあるものが優先
h1{
   color:red;
   width:90%;
   color:blue;
}
↑ここではh1はblueになる

④指定が重複したらより特定が強いものが優先
h1{
   color:red;
   width:90%;
}
header h1{
   color:blue;
}
↑ここではheader内のh1はcolorがblue、widthが90%になる
*/  