* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background-color: #fffff3;
    font-family: "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Noto Sans JP", sans-serif;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    position: relative;
}

/* ナビゲーション */
.nav-top {
    position: fixed;
    top: 0; left: 0; right: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 28px;
    z-index: 100;
}
.nav-coffee { display: none; }
.nav-links { display: flex; gap: 20px; }
.nav-link {
    font-size: 12px;
    letter-spacing: 0.08em;
    color: #3a2c1e;
    text-decoration: none;
    opacity: 0.6;
    transition: opacity 0.2s;
}
.nav-link:hover { opacity: 1; }
.lang-select-wrap { position: relative; }
.lang-select {
    appearance: none; -webkit-appearance: none;
    background: transparent;
    border: none;
    border-bottom: 1px solid #3a2c1e;
    font-size: 12px;
    letter-spacing: 0.05em;
    color: #3a2c1e;
    padding: 2px 18px 2px 4px;
    cursor: pointer; outline: none;
    font-family: inherit;
}
.lang-select-wrap::after {
    content: '▾';
    position: absolute; right: 2px; top: 50%;
    transform: translateY(-50%);
    font-size: 10px; color: #3a2c1e;
    pointer-events: none;
}

/* ロゴ：画面中央に大きく、他要素はその上に重ねる */
.logo-img {
    position: absolute;
    left: 50%; top: 50%;
    transform: translate(-50%, -50%);
    width: 400px;
    max-width: 90vw;
    height: auto;
    z-index: 1;
    user-select: none;
}

/* キャプション：ロゴ画像のビル群の下端あたりに重ねる */
/* JSで位置を計算 */
.caption {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    font-size: 12px;
    letter-spacing: 0.12em;
    color: #3a2c1e;
    opacity: 0.75;
    text-align: center;
    white-space: nowrap;
    z-index: 2;
}
.sp-br { display: none; }
@media (max-width: 640px) {
    .sp-br { display: inline; }
    .caption { white-space: normal; }
}

/* ロケット */
.rocket-wrap {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    cursor: pointer;
    width: 98px;
    z-index: 2;
}
.rocket-img { width: 80px; height: auto; display: block; margin: 0 auto; }
#rocket-flying { width: 98px; margin: 0; }
.rocket-flying { display: none; }

/* カタカタアニメーション */
@keyframes rattle {
    0%   { transform: translateX(0) rotate(0deg); }
    15%  { transform: translateX(-3px) rotate(-1.5deg); }
    30%  { transform: translateX(3px) rotate(1.5deg); }
    45%  { transform: translateX(-2px) rotate(-1deg); }
    60%  { transform: translateX(2px) rotate(1deg); }
    75%  { transform: translateX(-2px) rotate(-0.5deg); }
    90%  { transform: translateX(2px) rotate(0.5deg); }
    100% { transform: translateX(0) rotate(0deg); }
}
.rocket-img.rattling {
    animation: rattle 0.3s ease-in-out 6;
}

/* 言語選択・同意ダイアログ共通 */
.dialog-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.dialog-box {
    background: #fffff3;
    max-width: 460px;
    width: 100%;
    padding: 40px 36px 36px;
    border-radius: 6px;
    text-align: center;
    font-size: 15px;
    line-height: 2.0;
    color: #3a2c1e;
}

/* 言語選択ダイアログ */
#lang-dialog .dialog-box {
    max-width: 380px;
}
.lang-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 24px;
}
.lang-grid button {
    background: transparent;
    border: 1px solid rgba(58,44,30,0.25);
    color: #3a2c1e;
    font-family: inherit;
    font-size: 14px;
    padding: 12px 8px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
    letter-spacing: 0.04em;
}
.lang-grid button:hover {
    background: rgba(58,44,30,0.06);
    border-color: rgba(58,44,30,0.5);
}

/* 同意ダイアログ */
.consent-title {
    display: block;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 0;
    margin-bottom: 16px;
}
#consent-dialog .dialog-box {
    max-width: 480px;
}
#consent-dialog .dialog-box p {
    margin-bottom: 20px;
    padding: 0 10px;
}
#consent-dialog .consent-links {
    margin-bottom: 28px;
    font-size: 13px;
}
#consent-dialog .consent-links a {
    color: #3a2c1e;
    text-decoration: underline;
    text-underline-offset: 3px;
    opacity: 0.7;
    transition: opacity 0.2s;
}
#consent-dialog .consent-links a:hover {
    opacity: 1;
}
#consent-btn {
    display: inline-block;
    background: #3a2c1e;
    color: #fffff3;
    border: none;
    font-family: inherit;
    font-size: 15px;
    letter-spacing: 0.1em;
    padding: 12px 48px;
    border-radius: 4px;
    cursor: pointer;
    transition: opacity 0.2s;
}
#consent-btn:hover {
    opacity: 0.85;
}
