/* リセットとベーススタイル */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-pink: #FFB6C1;
    --color-blue: #87CEEB;
    --color-yellow: #FFE4B5;
    --color-light-blue: #E0F6FF;
    --color-light-pink: #FFE4E1;
    --color-light-yellow: #FFFACD;
}

body {
    font-family: 'Zen Maru Gothic', sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ヒーローセクション */
.hero {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://www.kfb.co.jp/special/assets/45th/hero-bg.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 0;
}

.hero-background::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://www.kfb.co.jp/special/assets/45th/bg2.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 1;
    mask: radial-gradient(ellipse at center,
            transparent 0%,
            transparent 40%,
            rgba(0, 0, 0, 0.1) 50%,
            rgba(0, 0, 0, 0.3) 60%,
            rgba(0, 0, 0, 0.5) 70%,
            rgba(0, 0, 0, 0.7) 80%,
            rgba(0, 0, 0, 0.9) 90%,
            rgba(0, 0, 0, 1) 100%);
    -webkit-mask: radial-gradient(ellipse at center,
            transparent 0%,
            transparent 40%,
            rgba(0, 0, 0, 0.1) 50%,
            rgba(0, 0, 0, 0.3) 60%,
            rgba(0, 0, 0, 0.5) 70%,
            rgba(0, 0, 0, 0.7) 80%,
            rgba(0, 0, 0, 0.9) 90%,
            rgba(0, 0, 0, 1) 100%);
}

.hero-background::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center,
            rgba(255, 255, 255, 1) 0%,
            rgba(255, 255, 255, 0.95) 15%,
            rgba(255, 255, 255, 0.8) 30%,
            rgba(255, 255, 255, 0.5) 50%,
            rgba(255, 255, 255, 0.2) 70%,
            rgba(255, 255, 255, 0) 100%);
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 100%;
    padding: 40px 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.hero-title {
    font-size: clamp(2rem, 5vw, 4rem);
    font-weight: 700;
    color: #fff;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3), 0 0 20px rgba(255, 255, 255, 0.5);
    margin-bottom: 30px;
    animation: titleEntrance 1.2s ease-out, titlePulse 2s ease-in-out 1.2s infinite;
    transform-origin: center;
    letter-spacing: 0.05em;
}

/* メインレイアウト：キャラクター、ロゴ、ロゴコンセプトを横並び */
.main-layout {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 1400px;
    margin: 20px auto;
    flex-wrap: wrap;
}

.character-container {
    flex: 0 0 auto;
    display: none;
    /* デフォルトでは非表示（スマホ用） */
}

.character {
    max-width: 350px;
    width: 100%;
    height: auto;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
    animation: floatGentle 4s ease-in-out infinite;
}

.character-container-mobile {
    display: none;
}

.character-mobile {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
    animation: float 3s ease-in-out infinite;
}

.logo-container {
    flex: 0 0 auto;
    animation: fadeInUp 1s ease-out 0.3s both;
    position: relative;
    padding: 50px 70px;
    overflow: visible;
    aspect-ratio: 1.3 / 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.logo-container::after {
    display: none;
}

.logo-container::before {
    content: '';
    position: absolute;
    top: -20px;
    left: -20px;
    right: -20px;
    bottom: -20px;
    background: linear-gradient(45deg,
            transparent 30%,
            rgba(135, 206, 235, 0.08) 40%,
            rgba(135, 206, 235, 0.08) 50%,
            transparent 60%),
        linear-gradient(-45deg,
            transparent 30%,
            rgba(135, 206, 235, 0.08) 40%,
            rgba(135, 206, 235, 0.08) 50%,
            transparent 60%),
        linear-gradient(90deg,
            transparent 40%,
            rgba(255, 182, 193, 0.08) 45%,
            rgba(255, 182, 193, 0.08) 55%,
            transparent 60%),
        linear-gradient(0deg,
            transparent 40%,
            rgba(255, 182, 193, 0.08) 45%,
            rgba(255, 182, 193, 0.08) 55%,
            transparent 60%);
    border-radius: 50%;
    z-index: -1;
    aspect-ratio: 1.3 / 1;
    filter: blur(8px);
    opacity: 0.7;
}

.main-logo {
    max-width: 520px;
    width: 100%;
    height: auto;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.2));
    position: relative;
    z-index: 2;
}

.logo-subtitle {
    font-size: clamp(2rem, 3.5vw, 3rem);
    font-weight: 500;
    color: #4682B4;
    margin-top: 15px;
    text-align: center;
    text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.8);
    z-index: 2;
    position: relative;
}

.concept-container {
    width: 100%;
    max-width: 600px;
    margin-top: 30px;
}

.concept-box {
    background: transparent;
    border-radius: 20px;
    padding: 30px;
    box-shadow: none;
    border: none;
    animation: fadeInUp 1s ease-out 0.5s both;
}

.announcement-container {
    width: 100%;
    max-width: 1000px;
    margin-top: 30px;
    animation: fadeInUp 1s ease-out 0.7s both;
}

.speech-bubble-wrapper {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.speech-bubble {
    position: relative;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 25px;
    padding: 25px 35px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    border: 3px solid rgba(135, 206, 235, 0.6);
    max-width: 700px;
    flex: 1;
    min-width: 280px;
}

.speech-bubble::before {
    display: none;
}

.speech-bubble::after {
    display: none;
}

.announcement-text {
    font-size: clamp(1.2rem, 2.2vw, 1.4rem);
    line-height: 2;
    color: #555;
    text-align: left;
    margin: 0;
    font-weight: 800;
}

/* 装飾用バルーン */
.balloons-decoration {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.balloon {
    position: absolute;
    display: block;
    width: 160px;
    height: 200px;
    text-decoration: none;
    opacity: 0.85;
    animation: floatBalloon 5s ease-in-out infinite;
    pointer-events: auto;
    cursor: pointer;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.balloon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

.balloon:hover {
    opacity: 1;
    transform: scale(1.1);
}

.balloon:hover img {
    filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.3));
}

/* ツールチップ（ホバー時の名前表示） */
.balloon::after {
    content: attr(title);
    position: absolute;
    bottom: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%) translateY(5px);
    background: linear-gradient(135deg, rgba(255, 182, 193, 0.95) 0%, rgba(135, 206, 235, 0.95) 100%);
    color: #333;
    padding: 10px 18px;
    border-radius: 20px;
    font-size: 15px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 1000;
    font-family: 'Zen Maru Gothic', sans-serif;
    font-weight: 700;
    letter-spacing: 0.5px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2),
        0 4px 10px rgba(255, 182, 193, 0.3),
        0 0 20px rgba(135, 206, 235, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.balloon::before {
    content: '';
    position: absolute;
    bottom: calc(100% + 2px);
    left: 50%;
    transform: translateX(-50%) translateY(5px);
    border: 8px solid transparent;
    border-top-color: rgba(255, 182, 193, 0.95);
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 1001;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.balloon:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.balloon:hover::before {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* PC表示時のバルーン配置（文字やロゴに被らない位置） */
.balloon-1 {
    top: 8%;
    left: 2%;
    animation-delay: 0s;
}

.balloon-2 {
    top: 15%;
    right: 3%;
    animation-delay: 0.7s;
}

.balloon-3 {
    top: 70%;
    left: 1%;
    animation-delay: 1.4s;
}

.balloon-4 {
    top: 60%;
    right: 2%;
    animation-delay: 2.1s;
}

.balloon-5 {
    top: 65%;
    left: 15%;
    animation-delay: 2.8s;
}

.balloon-6 {
    top: 12%;
    left: 50%;
    animation-delay: 3.5s;
}

.balloon-7 {
    top: 75%;
    right: 12%;
    animation-delay: 4.2s;
}

.balloon-8 {
    top: 35%;
    left: 1%;
    animation-delay: 4.9s;
}

.balloon-9 {
    top: 30%;
    right: 8%;
    animation-delay: 5.6s;
}

.balloon-10 {
    top: 10%;
    left: 25%;
    animation-delay: 6.3s;
}

/* バルーン装飾 */
/* アニメーション */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes titleEntrance {
    0% {
        opacity: 0;
        transform: translateY(-50px) scale(0.8) rotate(-5deg);
    }

    50% {
        transform: translateY(10px) scale(1.05) rotate(2deg);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1) rotate(0deg);
    }
}

@keyframes titlePulse {

    0%,
    100% {
        transform: scale(1);
        text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3), 0 0 20px rgba(255, 255, 255, 0.5);
    }

    50% {
        transform: scale(1.02);
        text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3), 0 0 30px rgba(255, 255, 255, 0.8), 0 0 40px rgba(255, 182, 193, 0.6);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px) rotate(0deg);
    }

    50% {
        transform: translateY(-20px) rotate(2deg);
    }
}

@keyframes floatGentle {
    0% {
        transform: translateY(0px) translateX(0px);
    }

    25% {
        transform: translateY(-15px) translateX(5px);
    }

    50% {
        transform: translateY(-25px) translateX(0px);
    }

    75% {
        transform: translateY(-15px) translateX(-5px);
    }

    100% {
        transform: translateY(0px) translateX(0px);
    }
}

@keyframes floatBalloon {

    0%,
    100% {
        transform: translateY(0px) translateX(0px);
    }

    25% {
        transform: translateY(-30px) translateX(10px);
    }

    50% {
        transform: translateY(-20px) translateX(-5px);
    }

    75% {
        transform: translateY(-35px) translateX(8px);
    }
}

@keyframes floatUp {
    0% {
        transform: translateY(100vh) translateX(0px);
        opacity: 0;
    }

    10% {
        opacity: 0.85;
    }

    100% {
        transform: translateY(-100vh) translateX(0px);
        opacity: 0.85;
    }
}

.section-title {
    font-size: clamp(1.2rem, 2vw, 1.5rem);
    font-weight: 700;
    color: #4682B4;
    margin-bottom: 15px;
    text-align: center;
    text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.8);
}

.concept-text {
    font-size: clamp(0.9rem, 1.5vw, 1rem);
    line-height: 1.8;
    color: #3f3f3f;
    text-align: left;
    text-shadow: 1px 1px 2px rgba(12, 12, 12, 0.8);
}

.announcement-box {
    background: rgba(255, 255, 255, 0.7);
    border-radius: 20px;
    padding: 30px 40px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
    border: 2px solid rgba(255, 182, 193, 0.4);
}

.announcement-text {
    font-size: clamp(1.2rem, 2.2vw, 1.4rem);
    line-height: 2;
    color: #555;
    text-align: center;
    margin: 0;
}

/* フッター */
.footer {
    background: linear-gradient(135deg,
            rgba(135, 206, 235, 0.2) 0%,
            rgba(255, 182, 193, 0.2) 100%);
    padding: 30px 0;
    text-align: center;
}

.footer-link {
    margin-bottom: 10px;
}

.footer-link a {
    font-size: 1.5rem;
    color: #4682B4;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.footer-link a:hover {
    color: #FF69B4;
    text-decoration: underline;
}

.copyright {
    font-size: 0.9rem;
    color: #666;
}

/* レスポンシブデザイン */
@media (max-width: 1024px) {
    .main-layout {
        flex-direction: column;
        gap: 20px;
    }

    .concept-container {
        width: 100%;
        max-width: 600px;
        margin-top: 30px;
    }

    .concept-text {
        text-align: center;
    }

    .speech-bubble-wrapper {
        flex-direction: column;
        align-items: center;
    }

    .speech-bubble::before {
        display: none;
    }

    .speech-bubble::after {
        display: none;
    }

    /* タブレット表示時のバルーン配置 */
    .balloon {
        width: 100px;
        height: 125px;
        pointer-events: none;
        cursor: default;
    }

    .balloon:hover {
        transform: none;
    }

    .balloon-1 {
        top: 5%;
        left: 2%;
    }

    .balloon-2 {
        top: 8%;
        right: 2%;
    }

    .balloon-3 {
        top: 80%;
        left: 2%;
    }

    .balloon-4 {
        top: 75%;
        right: 2%;
    }

    .balloon-5 {
        top: 85%;
        left: 12%;
    }

    .balloon-6 {
        top: 10%;
        left: 50%;
    }

    .balloon-7 {
        top: 82%;
        right: 10%;
    }

    .balloon-8 {
        top: 20%;
        left: 8%;
    }

    .balloon-9 {
        top: 50%;
        right: 8%;
    }

    .balloon-10 {
        top: 40%;
        left: 25%;
    }
}

@media (max-width: 768px) {
    .hero-background::before {
        background-image: url('https://www.kfb.co.jp/special/assets/45th/sp-bg2.jpg');
        mask: linear-gradient(to bottom,
                transparent 0%,
                transparent 40%,
                rgba(0, 0, 0, 0.1) 50%,
                rgba(0, 0, 0, 0.3) 60%,
                rgba(0, 0, 0, 0.5) 70%,
                rgba(0, 0, 0, 0.7) 80%,
                rgba(0, 0, 0, 0.9) 90%,
                rgba(0, 0, 0, 1) 100%);
        -webkit-mask: linear-gradient(to bottom,
                transparent 0%,
                transparent 40%,
                rgba(0, 0, 0, 0.1) 50%,
                rgba(0, 0, 0, 0.3) 60%,
                rgba(0, 0, 0, 0.5) 70%,
                rgba(0, 0, 0, 0.7) 80%,
                rgba(0, 0, 0, 0.9) 90%,
                rgba(0, 0, 0, 1) 100%);
    }

    .hero-content {
        padding: 20px 15px;
    }

    .main-layout {
        gap: 15px;
        justify-content: center;
        align-items: center;
        width: 100%;
        margin: 0 auto;
    }

    .main-logo {
        max-width: 320px;
    }

    .logo-subtitle {
        font-size: clamp(1.6rem, 2.8vw, 2rem);
        margin-top: 10px;
    }

    .logo-container {
        padding: 30px 45px;
        margin: 0 auto;
        width: fit-content;
        aspect-ratio: auto;
    }

    .logo-container::before {
        aspect-ratio: auto;
    }

    .concept-container {
        width: 100%;
        max-width: 600px;
        margin-top: 20px;
    }

    .concept-box {
        width: 100%;
        max-width: 600px;
    }

    .logo-container::after {
        display: none;
    }

    .logo-container::before {
        top: -15px;
        left: -15px;
        right: -15px;
        bottom: -15px;
    }

    .character-container {
        display: none;
    }

    .character-container-mobile {
        display: block;
        position: absolute;
        right: 30px;
        top: -30px;
        z-index: 10;
    }

    .character-mobile {
        max-width: 100px;
    }

    .concept-container {
        width: 100%;
        max-width: 100%;
        margin-top: 15px;
    }

    .concept-box {
        padding: 25px 20px;
    }

    .speech-bubble {
        padding: 20px 25px;
        max-width: 100%;
    }

    .speech-bubble-wrapper {
        gap: 15px;
    }

    /* スマホ表示時のバルーン配置（下から上に浮かび上がる） */
    .balloon {
        width: 100px;
        height: 125px;
        animation: floatUp 15s linear infinite;
        top: auto !important;
        bottom: -100px;
        pointer-events: none;
        cursor: default;
    }

    .balloon:hover {
        transform: none;
    }

    .balloon-1 {
        left: 5%;
        animation-delay: 0s;
    }

    .balloon-2 {
        right: 5%;
        animation-delay: 2s;
    }

    .balloon-3 {
        left: 15%;
        animation-delay: 4s;
    }

    .balloon-4 {
        right: 15%;
        animation-delay: 6s;
    }

    .balloon-5 {
        left: 25%;
        animation-delay: 8s;
    }

    .balloon-6 {
        left: 50%;
        animation-delay: 10s;
    }

    .balloon-7 {
        right: 25%;
        animation-delay: 12s;
    }

    .balloon-8 {
        left: 35%;
        animation-delay: 14s;
    }

    .balloon-9 {
        right: 35%;
        animation-delay: 16s;
    }

    .balloon-10 {
        left: 75%;
        animation-delay: 18s;
    }

    .concept-text {
        font-size: 0.95rem;
        line-height: 1.8;
    }

    .announcement-text {
        font-size: 1.1rem;
        line-height: 1.8;
    }

    /* スマホ時はメッセージ内の改行タグを非表示にして1行扱いにする */
    .announcement-text br {
        display: none;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 1.5rem;
        margin-bottom: 20px;
    }

    .main-logo {
        max-width: 260px;
    }

    .logo-subtitle {
        font-size: clamp(1.4rem, 2.5vw, 1.8rem);
        margin-top: 8px;
    }

    .logo-container {
        padding: 25px 35px;
        aspect-ratio: auto;
    }

    .logo-container::before {
        aspect-ratio: auto;
    }

    .logo-container::after {
        display: none;
    }

    .logo-container::before {
        top: -12px;
        left: -12px;
        right: -12px;
        bottom: -12px;
    }

    .character-container-mobile {
        right: -5px;
        bottom: -15px;
    }

    .character-mobile {
        max-width: 80px;
    }

    .concept-box {
        padding: 20px 15px;
    }

    .speech-bubble {
        padding: 18px 20px;
    }

    .speech-bubble::before {
        display: none;
    }

    .speech-bubble::after {
        display: none;
    }
}

/* PCでファーストビューに収まるように調整 */
@media (min-width: 1025px) {
    .character-container {
        display: block;
        /* PC表示時に表示 */
    }

    .main-layout {
        position: relative;
        justify-content: center;
        align-items: center;
    }

    .character-container {
        position: absolute;
        left: 5%;
        top: 50%;
        transform: translateY(-50%);
        z-index: 3;
    }

    .character {
        max-width: 400px;
    }

    .balloon {
        width: 220px;
        height: 280px;
    }

    .balloon-6 {
        top: 5%;
        left: 65%;
    }

    .hero-background::before {
        mask: linear-gradient(to right,
                transparent 0%,
                transparent 65%,
                rgba(0, 0, 0, 0.1) 70%,
                rgba(0, 0, 0, 0.3) 75%,
                rgba(0, 0, 0, 0.5) 80%,
                rgba(0, 0, 0, 0.7) 85%,
                rgba(0, 0, 0, 0.9) 92%,
                rgba(0, 0, 0, 1) 100%);
        -webkit-mask: linear-gradient(to right,
                transparent 0%,
                transparent 65%,
                rgba(0, 0, 0, 0.1) 70%,
                rgba(0, 0, 0, 0.3) 75%,
                rgba(0, 0, 0, 0.5) 80%,
                rgba(0, 0, 0, 0.7) 85%,
                rgba(0, 0, 0, 0.9) 92%,
                rgba(0, 0, 0, 1) 100%);
    }

    .hero-content {
        padding: 12px 20px 10px;
        justify-content: space-between;
        box-sizing: border-box;
    }

    .hero-title {
        font-size: clamp(2.3rem, 3.2vw, 3.2rem);
        margin-bottom: 8px;
        line-height: 1.2;
    }

    .main-layout {
        margin: 5px 0;
        gap: 18px;
        flex-shrink: 1;
    }

    .main-logo {
        max-width: 420px;
    }

    .logo-subtitle {
        font-size: clamp(1.8rem, 3vw, 2.5rem);
        margin-top: 12px;
    }

    .logo-container {
        padding: 40px 60px;
        aspect-ratio: 1.3 / 1;
    }

    .logo-container::after {
        display: none;
    }

    .logo-container::before {
        top: -18px;
        left: -18px;
        right: -18px;
        bottom: -18px;
        aspect-ratio: 1.3 / 1;
        border-radius: 50%;
    }

    .character {
        max-width: 280px;
    }

    .concept-container {
        width: 100%;
        max-width: 600px;
        margin-top: 15px;
    }

    .concept-box {
        padding: 20px 25px;
    }

    .section-title {
        font-size: clamp(1.1rem, 1.5vw, 1.3rem);
        margin-bottom: 10px;
    }

    .concept-text {
        font-size: clamp(0.85rem, 1.2vw, 0.95rem);
        line-height: 1.6;
    }

    .announcement-container {
        margin-top: 5px;
        flex-shrink: 0;
        margin-bottom: 0;
    }

    .speech-bubble {
        padding: 15px 25px;
        max-width: 650px;
    }

    .announcement-text {
        font-size: clamp(0.95rem, 1.4vw, 1.15rem);
        line-height: 1.6;
    }

    .speech-bubble-wrapper {
        position: relative;
        gap: 20px;
        justify-content: center;
        align-items: center;
        width: 100%;
    }

    .speech-bubble {
        margin: 0 auto;
        max-width: 650px;
    }
}