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

body {
    font-family: "ヒラギノ丸ゴ Pro", "Hiragino Maru Gothic Pro", "Meiryo UI", "メイリオ", Meiryo, "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", "ＭＳ Ｐゴシック", "MS PGothic", Arial, Helvetica, sans-serif;
    min-height: 100vh;
    padding: 20px;
    padding-top: 80px; /* バナー分の余白 */
    line-height: 1;
    background: -moz-linear-gradient(top, #202632 0%, #202632 200px, #000000 680px, #000000 100%);
    background: -webkit-linear-gradient(top, #202632 0%, #202632 200px, #000000 680px, #000000 100%);
    background: linear-gradient(to bottom, #202632 0%, #202632 200px, #000000 680px, #000000 100%);
    display: flex; /* インラインスタイルで初期非表示、JSで表示に切り替え */
    justify-content: center;
    align-items: center;
}

/* PWAインストールバナー */
.pwa-install-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: white;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    padding: 12px 16px;
    display: none;
    align-items: center;
    z-index: 1000;
    animation: slideDown 0.3s ease;
}

.pwa-install-banner.show {
    display: flex;
}

@keyframes slideDown {
    from {
        transform: translateY(-100%);
    }
    to {
        transform: translateY(0);
    }
}

.pwa-banner-icon {
    width: 48px;
    height: 48px;
    margin-right: 16px;
    border-radius: 10px;
}

.pwa-banner-content {
    flex: 1;
}

.pwa-banner-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 2px;
}

.pwa-banner-subtitle {
    font-size: 13px;
    color: #666;
}

.pwa-banner-buttons {
    display: flex;
    gap: 8px;
}

/* Android警告用スタイル */
.pwa-banner-subtitle.warning {
    color: #856404;
    font-weight: 500;
}

.pwa-banner-btn {
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    line-height: 1.8;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.pwa-banner-install {
    background: #4CAF50;
    color: white;
}

.pwa-banner-install:hover {
    background: #50cd54;
}

.pwa-banner-install img{
    height: 14px;
    width: auto;
    display: inline;
    margin-left: 8px;

}

.pwa-banner-close {
    background: transparent;
    color: #999;
}

.pwa-banner-close:hover {
    color: #666;
}

.container {
    background-color: #282828;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.325);
    border-radius: 8px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 16px;
    padding: 40px;
    max-width: 500px;
    width: 100%;
}

.header {
    text-align: center;
    margin-bottom: 30px;
}

.header h1 {
    color: #e3c383;
    font-size: 28px;
    margin-bottom: 10px;
}

.header .bell-icon img {
    height: 40px;
    margin-bottom: -10px;
}
.header p {
    color: #f2f2f2;
    font-size: 16px;
    line-height: 1.5;
}

.status-card {
    /*background: #f8f9fa;*/
    background: #333333;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    text-align: center;
    display: block; /* 初期表示（確認中メッセージ用） */
}

.status-indicator {
    font-size: 48px;
    margin-bottom: 10px;
}

.status-text {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 20px;
    color: #ffffff;
}

.status-description {
    font-size: 14px;
    color: #f2f2f2;
}

.user-input {
    margin-bottom: 20px;
}

.user-input label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #f2f2f2;
}

.user-input input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.user-input input:focus {
    outline: none;
    border-color: #667eea;
}

small {
    color: #f2f2f2;
    font-size: 12px;
    display: block;
    margin-top: 4px;
}

.button {
    width: 100%;
    padding: 14px 20px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: 10px;
}

.button-primary {
    color: #f2f2f2;
    background-color: #65707d;
    -webkit-box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.625);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.625);
}

.button-primary:hover {
    background-image: linear-gradient(99deg, rgba(255, 255, 255, 0.2) 30%, rgba(255, 255, 255, 0.5) 35%, rgba(255, 255, 255, 0.2) 40%);
    background-size: 500% 100%;
    -webkit-animation: shine 0.75s;
    animation: shine 0.75s;
}

.button-secondary {
    color: #ffffff;
    background: #4CAF50;
}

.button-secondary:hover {
    background-image: linear-gradient(99deg, rgba(255, 255, 255, 0.2) 30%, rgba(255, 255, 255, 0.5) 35%, rgba(255, 255, 255, 0.2) 40%);
    background-size: 500% 100%;
    -webkit-animation: shine 0.75s;
    animation: shine 0.75s;
}

.admin-link {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e1e5e9;
}

.admin-link a {
    color: #0099cd;
    text-decoration: none;
    font-size: 14px;
}

.admin-link a:hover {
    text-decoration: underline;
}

.notification-log {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 16px;
    margin-top: 20px;
    max-height: 200px;
    overflow-y: auto;
    font-size: 12px;
    line-height: 1.4;
    color: #333;
    white-space: pre-wrap;
}

@media (max-width: 600px) {
    body {
        padding: 20px 10px;
        padding-top: 80px;
    }

    .container {
        position: relative;
        transform: none;
        top: auto;
        left: auto;
        margin: 0;
        padding: 20px 15px;
        width: calc(100% - 20px);
        max-width: none;
    }

    .header h1 {
        font-size: 24px;
    }

    .header p {
        font-size: 14px;
    }

    .progress-container {
        padding: 15px;
        margin: 15px 0;
    }

    .progress-text {
        font-size: 13px;
    }

    .progress-steps {
        flex-wrap: wrap;
        gap: 3px;
    }

    .progress-step {
        font-size: 9px;
        flex: 1;
        min-width: 50px;
        text-align: center;
    }
}

@-webkit-keyframes shine {
    0% {
        background-position: 100% 50%;
    }
    to {
        background-position: 0 50%;
    }
}

@keyframes shine {
    0% {
        background-position: 100% 50%;
    }
    to {
        background-position: 0 50%;
    }
}

/* プログレスバーのスタイル */
.progress-container {
    display: none;
    margin: 20px 0;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 20px;
    text-align: center;
}

.progress-text {
    color: #f2f2f2;
    font-size: 14px;
    margin-bottom: 15px;
    font-weight: 500;
}

.progress-bar-container {
    width: 100%;
    height: 8px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 0%;
}

.progress-steps {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
}

.progress-step {
    font-size: 10px;
    color: #999;
}

.progress-step.active {
    color: #667eea;
    font-weight: 600;
}

/* iOS インストール手順モーダル */
.ios-install-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.3s ease;
}

.ios-install-modal.show {
    display: flex;
}

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

.ios-install-content {
    position: relative;
    animation: slideUp 0.3s ease;
    background-color: #282828;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.325);
    border-radius: 8px;
    padding: 25px;
    max-width: 420px;
    width: 100%;
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.ios-install-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.ios-install-header h3 {
    margin: 0;
    color: #e3c383;;
    font-size: 18px;
    font-weight: 600;
}

.ios-install-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    background: #5c5a5d;
    color: #fff;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s;
}

.ios-install-close:hover {
    background-color: #666;
}

.ios-install-steps {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.ios-install-notice {
    margin-bottom: 25px;
    padding: 15px;
    background: rgba(255, 193, 7, 0.15);
    border: 1px solid rgba(255, 193, 7, 0.4);
    border-radius: 8px;
    color: #ffc107;
    font-size: 13px;
    line-height: 1.5;
    text-align: center;
}

.ios-step {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    height: 76px;
    background: #4b2794;
    background: linear-gradient(90deg, #374ba7, #4b2794);
    border-radius: 8px;
    padding: 15px;
}

.ios-step-number {
    font-size: 24px;
    width: 54px;
    height: 64px;
    background: #764ba2;
    background: linear-gradient(90deg, #667eea, #764ba2);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    flex-shrink: 0;
    --f: .3em; /* control the folded part*/
    --r: .8em; /* control the ribbon shape */
    left: 20px;
    margin-top: -23px;
    padding: .2em;
    border-left: var(--f) solid #0005;
    border-bottom: var(--r) solid #0000;
    clip-path: polygon(var(--f) 0,100% 0,100% calc(100% - var(--r)),calc(50% + var(--f)/2) 86%, var(--f) calc(100% - var(--r)),var(--f) var(--f),0 var(--f));
}


.ios-step-text {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #fff;
    font-size: 15px;
    line-height: 1.8;
    text-align: left;
}

.ios-step-icon {
    font-size: 24px;
    width: 24px;
    margin-left: 16px;
    margin-right: 4px;
    margin-top: 2px;
}

/* ステータスアイコン（新デザイン） */
.status-icon {
    border-radius: 50%;
    width: 2em;
    height: 2em;
    margin: 0 auto 20px auto;
}

.status-green {
    background: linear-gradient(180deg, #84ff00 0%, #119400 100% );
    border: 1px solid #84ff00;
}

.status-red {
    background: linear-gradient(180deg, #ff0000 0%, #b20000 100% );
    border: 1px solid #ff0000;
}

.status-yellow {
    background: linear-gradient(180deg, #ffd83e 0%, #d19600 100% );
    border: 1px solid #ffd83e;
}

/* パーティクルアニメーション */
.thumb-particles {
    position: relative;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    overflow: hidden;
}

.thumb-particle {
    position: absolute;
    width: 3px;
    height: 3px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    box-shadow: 0 0 5px rgba(100, 200, 255, 0.4);
    animation: thumb-particle-float 3s infinite ease-out;
    opacity: 0;
}

.thumb-particle:nth-child(1) {
    top: 70%;
    left: 30%;
    animation-delay: 0.2s;
}

.thumb-particle:nth-child(2) {
    top: 60%;
    left: 60%;
    animation-delay: 0.6s;
}

.thumb-particle:nth-child(3) {
    top: 50%;
    left: 40%;
    animation-delay: 1s;
}

.thumb-particle:nth-child(4) {
    top: 40%;
    left: 70%;
    animation-delay: 1.4s;
}

.thumb-particle:nth-child(5) {
    top: 80%;
    left: 50%;
    animation-delay: 1.8s;
}

@keyframes thumb-particle-float {
    0% {
        transform: translateY(0) scale(1);
        opacity: 0;
    }
    20% {
        opacity: 0.8;
    }
    100% {
        transform: translateY(-30px) scale(0);
        opacity: 0;
    }
}
