/* === Top Page Variables & Resets === */
:root {
    --cyan-bg: #00ffff;
    --red-border: #ff0000;
    --yellow-fill: #ffff00;
}

body.top-page-body {
    background-color: var(--cyan-bg);
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    font-family: 'Noto Sans JP', sans-serif;
}

.top-page-container {
    width: 100%;
    max-width: 400px; /* Mobile width */
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    border-left: 2px solid black;
    border-right: 2px solid black;
    box-sizing: border-box;
    position: relative;
    overflow-y: auto;
    padding: 20px;
}

/* === Logo === */
.top-logo-box {
    position: absolute;
    top: 15px; /* 約4mm */
    left: 20px; /* 約5mm */
    width: 75px;
    height: 75px;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
}

.top-logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* === Title === */
.top-title-area {
    text-align: center;
    margin-top: 60px; /* 2mm上に移動 */
    margin-bottom: 0px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.main-title-img {
    max-width: 90%;
    height: auto;
    object-fit: contain;
    margin-bottom: 2px; /* 余白を半分以下に */
}

.sub-title {
    font-size: 1.25rem; /* 前回(1.4rem)と今回(1.1rem)の中間 */
    letter-spacing: 1.5px; /* 前回(2px)と今回(1px)の中間 */
    color: black;
    font-weight: 900;
    margin: 0px 0 2px 0; /* スペースを半分以下に */
}

.catch-phrase-images {
    display: flex;
    flex-direction: column;
    align-items: center; /* センター揃え */
    gap: 0px;
    margin-top: 3px; /* スペースを半分に */
    width: 100%;
}

.catch-img-1 {
    max-width: 85%;
    height: auto;
    object-fit: contain;
    margin-bottom: -2px; /* 余白を20%に（元画像の余白カットを考慮） */
}

.catch-img-2 {
    max-width: 85%;
    height: auto;
    object-fit: contain;
    margin-bottom: -5px; /* 矢印との間隔は現状維持（元画像の余白を考慮） */
}

/* === Chevron === */
.chevron-graphic {
    width: 100%;
    display: flex;
    justify-content: center; /* センター揃え */
    margin: 0px 0 20px 0;
}

.arrows-img {
    width: 260px; /* 大サイズ維持 */
    height: auto;
    object-fit: contain;
}

/* === Buttons Area === */
.top-buttons-area {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.top-btn {
    padding: 8px 30px;
    font-size: 1.1rem;
    font-weight: bold;
    background-color: white;
    border: 2px solid black;
    border-radius: 8px;
    cursor: pointer;
    text-align: center;
    min-width: 150px;
}

.login-row {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    width: 100%;
}

.login-label {
    font-size: 1.1rem;
    font-weight: bold;
}

.login-input-group {
    display: flex;
    align-items: center;
    gap: 5px;
}

.top-input {
    padding: 10px;
    border: 2px solid black;
    border-radius: 8px;
    width: 200px;
    font-size: 1rem;
}

.top-play-btn {
    background-color: red;
    border: 2px solid black;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}

.top-play-btn svg {
    width: 20px;
    height: 20px;
}

/* === Footer Links === */
.top-footer-links {
    margin-top: auto; /* pushes to bottom */
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding-top: 30px;
}

.top-footer-links a {
    color: #ff00ff; /* Magenta/Pink */
    text-decoration: none;
    font-weight: bold;
    font-size: 0.9rem;
}

.top-footer-links a:hover {
    text-decoration: underline;
}

/* === Modals === */
.modal {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    background: rgba(0,0,0,0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}
.modal.hidden {
    display: none;
}
.modal-content {
    background: white;
    padding: 20px;
    border-radius: 8px;
    width: 90%;
    max-width: 400px;
    max-height: 85vh;
    overflow-y: auto;
    box-sizing: border-box;
}

/* Reg Modal */
.reg-modal-title {
    margin-top: 0;
    font-size: 1.3rem;
    border-bottom: 2px solid #ccc;
    padding-bottom: 10px;
}
.reg-form-group {
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}
.reg-form-group label {
    font-size: 0.9rem;
    font-weight: bold;
}
.reg-input {
    width: 100%;
    padding: 10px;
    margin-top: 5px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1rem;
    box-sizing: border-box;
}

select.reg-input {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23007CB2%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E");
    background-repeat: no-repeat;
    background-position: right 10px top 50%;
    background-size: 12px auto;
    background-color: white;
}
.reg-note {
    font-size: 0.75rem;
    color: #666;
}
.reg-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
}
.reg-next-btn, .reg-close-btn {
    padding: 10px 20px;
    border-radius: 20px;
    border: 1px solid black;
    font-weight: bold;
    cursor: pointer;
}
.reg-next-btn { background: white; }
.reg-close-btn { background: #eee; }

/* Legal Modal */
.legal-modal-content {
    max-width: 500px;
}
.legal-text-area {
    font-size: 0.85rem;
    line-height: 1.6;
    color: #333;
    padding: 10px;
    background: #f9f9f9;
    border: 1px solid #eee;
    border-radius: 4px;
    max-height: 50vh;
    overflow-y: auto;
    margin-bottom: 15px;
}

/* Subscription Plans */
.reg-plan-section {
    margin-top: 15px;
    padding-top: 15px;
}
.plan-title {
    font-size: 0.95rem;
    font-weight: bold;
    margin-bottom: 10px;
}
.plan-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    font-size: 0.9rem;
}
.plan-select-btn {
    padding: 4px 12px;
    border-radius: 12px;
    border: 1px solid black;
    background: white;
    cursor: pointer;
    font-weight: bold;
}
.plan-select-btn.selected {
    background: black;
    color: white;
}
.plan-desc-box {
    font-size: 0.8rem;
    background: #f0f8ff;
    border: 1px solid #b0c4de;
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 4px;
    line-height: 1.4;
}
.plan-note {
    font-size: 0.75rem;
    color: #666;
    margin-top: 15px;
    line-height: 1.4;
}
