/* kujo.html専用スタイル */

/* サイト背景をbg 4.pngに変更 */
.container {
    background-image: url('assets/bg 4.png');
    background-size: auto;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

/* ロゴコンテナ */
.logo-container {
    display: flex;
    justify-content: center;
    padding: 20px 0;
}

.logo {
    max-width: 200px;
    height: auto;
}

/* 結果背景のスタイル */
.result-background {
    position: relative;
    width: 100%;
    display: flex;
    justify-content: center;
    margin: 10px 0;
}

.result-bg-img {
    max-width: 100%;
    width: 80%;
    height: auto;
}

/* 結果テキストのスタイル */
.result-text-container {
    position: absolute;
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.result-text-img {
    max-width: 50%;
    width: 50%;
    height: auto;
    display: block;
    margin: 0 auto;
}

/* キャラクター画像のスタイル */
.character-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    width: auto;
    height: auto;
}

.character-img {
    width: 700px;
    height: auto;
    display: block;
    /* bg-resultの横枠よりも大きく表示 */
}


/* シェアボタンのスタイル */
.share-container {
    position: absolute;
    bottom: 10%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    width: 100%;
    display: flex;
    justify-content: center;
}

.share-img {
    width: 35%;
    height: auto;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.share-img:hover {
    transform: scale(1.05);
}

/* ボタン群のスタイル */
.button-group {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    margin-top: 30px;
}

.return-to-top, .official-url {
    display: flex;
    justify-content: center;
    width: 100%;
}

.button-img {
    max-width: 300px;
    width: 80%;
    height: auto;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.button-img:hover {
    transform: scale(1.05);
}

/* フッターのスタイル */
.footer-section {
    width: 100%;
    margin-top: 30px;
    margin-bottom: 0;
    padding-bottom: 0;
}

.footer-banner-img {
    width: 100%;
    height: auto;
    display: block;
    margin-bottom: 0;
    padding-bottom: 0;
}

/* レスポンシブデザイン */
@media screen and (min-width: 768px) and (max-width: 1023px) {
    /* タブレット・小さなPC画面 */
    .logo {
        max-width: 220px;
    }
    
    .result-bg-img {
        width: 75%;
    }
    
    .result-text-img {
        max-width: 55%;
        width: 55%;
    }
    
    .character-img {
        width: 550px;
    }
    
    .share-img {
        width: 35%;
    }
    
    .button-img {
        max-width: 350px;
        width: 65%;
    }
}

@media screen and (min-width: 1024px) {
    /* 大画面PC版のスタイル */
    .logo {
        max-width: 300px;
    }
    
    .result-bg-img {
        width: 70%;
    }
    
    .result-text-img {
        max-width: 60%;
        width: 60%;
    }
    
    .character-img {
        width: 750px;
    }
    
    
    .share-img {
        width: 40%;
    }
    
    .button-img {
        max-width: 450px;
        width: 50%;
    }
}

/* 小さめタブレット版 */
@media screen and (min-width: 600px) and (max-width: 767px) {
    .container {
        background-size: auto;
        background-attachment: scroll;
    }
    
    .logo {
        max-width: 200px;
    }
    
    .result-background {
        margin: 12px 0;
    }
    
    .result-bg-img {
        width: 80%;
        max-width: 360px;
    }
    
    .result-text-container {
        top: 8%;
    }
    
    .result-text-img {
        max-width: 60%;
        width: 60%;
    }
    
    .character-container {
        top: 50%;
        width: auto;
    }
    
    .character-img {
        width: 420px;
        max-width: 420px;
    }
    
    .share-container {
        bottom: 8%;
    }
    
    .share-img {
        width: 40%;
    }
    
    .button-img {
        max-width: 300px;
        width: 80%;
    }
    
    .button-group {
        gap: 18px;
        margin-top: 25px;
    }
    
    .footer-section {
        margin-top: 20px;
        margin-bottom: 0;
        padding-bottom: 0;
    }
    
    .footer-banner-img {
        margin-bottom: 0;
        padding-bottom: 0;
        display: block;
        vertical-align: bottom;
    }
}

/* 超小画面対応 */
@media screen and (max-width: 480px) {
    html, body {
        height: 100vh !important;
        max-height: 100vh !important;
        overflow: hidden !important;
    }
    
    .container {
        background-size: auto;
        background-attachment: scroll;
        height: 100vh !important;
        min-height: 100vh !important;
        max-height: 100vh !important;
        overflow: hidden !important;
        position: relative;
    }
    
    .logo {
        max-width: 160px;
    }
    
    .footer-section {
        position: absolute;
        bottom: 0;
        width: 100%;
        margin: 0 !important;
        padding: 0 !important;
        height: auto;
        max-height: 15vh;
        overflow: hidden;
    }
    
    .footer-banner-img {
        width: 100%;
        height: auto;
        margin: 0 !important;
        padding: 0 !important;
        vertical-align: bottom;
        display: block;
        max-height: 15vh;
        object-fit: cover;
    }
    
    .result-background {
        margin: 8px 0;
    }
    
    .result-bg-img {
        width: 70%;
        max-width: 280px;
    }
    
    .result-text-container {
        top: 8%;
    }
    
    .result-text-img {
        max-width: 40%;
        width: 40%;
    }
    
    .character-container {
        top: 50%;
        width: auto;
    }
    
    .character-img {
        width: 320px;
        max-width: 320px;
    }
    
    .share-container {
        bottom: 8%;
    }
    
    .share-img {
        width: 30%;
    }
    
    .button-img {
        max-width: 260px;
        width: 90%;
    }
    
    .button-group {
        gap: 12px;
        margin-top: 20px;
    }
    
    .footer-section {
        margin-top: 15px;
        margin-bottom: 0;
        padding-bottom: 0;
    }
    
    .footer-banner-img {
        margin-bottom: 0;
        padding-bottom: 0;
        display: block;
        vertical-align: bottom;
    }
    
    html, body {
        height: auto !important;
        min-height: auto !important;
        max-height: none !important;
    }
    
    body::before, body::after {
        height: 100% !important;
        position: absolute !important;
        top: 0;
        bottom: auto;
    }
}

/* スマホ版の追加調整 */
@media screen and (min-width: 481px) and (max-width: 599px) {
    .container {
        background-size: auto;
        background-attachment: scroll;
    }
    
    .logo {
        max-width: 180px;
    }
    
    .result-background {
        margin: 15px 0;
    }
    
    .result-bg-img {
        width: 75%;
        max-width: 320px;
    }
    
    .result-text-container {
        top: 8%;
    }
    
    .result-text-img {
        max-width: 75%;
        width: 75%;
    }
    
    .character-container {
        top: 50%;
        width: auto;
    }
    
    .character-img {
        width: 380px;
        max-width: 380px;
    }
    
    .share-container {
        bottom: 8%;
    }
    
    .share-img {
        width: 60%;
    }
    
    .button-img {
        max-width: 280px;
        width: 85%;
    }
    
    .button-group {
        gap: 15px;
        margin-top: 25px;
    }
    
    .footer-section {
        margin-top: 20px;
        margin-bottom: 0;
        padding-bottom: 0;
    }
    
    .footer-banner-img {
        margin-bottom: 0;
        padding-bottom: 0;
        display: block;
        vertical-align: bottom;
    }
    
    /* 追加のスマホ専用余白削除 */
    html, body {
        height: auto !important;
        min-height: auto !important;
        max-height: none !important;
    }
    
    body::before, body::after {
        height: 100% !important;
        position: absolute !important;
        top: 0;
        bottom: auto;
    }
}

/* アニメーション効果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.result-background {
    animation: fadeInUp 0.6s ease-out;
}

.button-group {
    animation: fadeInUp 0.8s ease-out;
}
