/* 基础样式：移动端优先设计 */
.cfp-wrapper {
    box-sizing: border-box;
    max-width: 480px;
    margin: 0 auto;
    padding: 16px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    color: #222;
    background-color: #f5f5f7;
    transition: background-color 0.3s ease;
    position: relative;
}

.cfp-section {
    background-color: #ffffff;
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 16px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.04);
}

.cfp-section-title {
    font-size: 18px;
    margin: 0 0 8px;
}

.cfp-section-desc {
    font-size: 14px;
    color: #666;
    margin: 0 0 10px;
}

.cfp-tip {
    font-size: 13px;
    color: #999;
}

/* 通用按钮 */
.cfp-button-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 8px;
}

.cfp-btn {
    border: none;
    border-radius: 999px;
    padding: 10px 16px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    outline: none;
    transition: transform 0.08s ease, box-shadow 0.08s ease, background-color 0.15s ease;
    background-color: #e0e0e0;
    color: #222;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 110px;
}

.cfp-btn:active {
    transform: scale(0.97);
    box-shadow: 0 2px 6px rgba(0,0,0,0.15) inset;
}

/* 主色按钮 */
.cfp-btn-primary {
    background-color: #007aff;
    color: #ffffff;
}

.cfp-btn-primary:hover {
    background-color: #0060d0;
}

/* 次级按钮 */
.cfp-btn-secondary {
    background-color: #e5e5ea;
    color: #111;
}

.cfp-btn-secondary:hover {
    background-color: #d1d1d6;
}

/* 芯片按钮 */
.cfp-btn-chip {
    padding: 6px 10px;
    font-size: 13px;
    min-width: auto;
}

/* 欢迎 / 送客颜色 */
.cfp-btn-welcome {
    background-color: #34c759;
    color: #ffffff;
    flex: 1 1 45%;
}

.cfp-btn-welcome:hover {
    background-color: #2fa54c;
}

.cfp-btn-goodbye {
    background-color: #ff3b30;
    color: #ffffff;
    flex: 1 1 45%;
}

.cfp-btn-goodbye:hover {
    background-color: #d8342b;
}

/* 冰块规格区域（控制端：细长条列表布局） */
.cfp-ice-grid {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 8px;
}

.cfp-ice-item {
    border-radius: 10px;
    padding: 8px 10px;
    background-color: #f2f2f7;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
}

.cfp-ice-label {
    font-size: 14px;
    font-weight: 600;
}

.cfp-ice-qty-controls {
    display: flex;
    align-items: center;
    gap: 6px;
}

.cfp-qty-btn {
    border: none;
    border-radius: 999px;
    width: 30px;
    height: 30px;
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    background-color: #e5e5ea;
    color: #111;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.cfp-qty-btn:active {
    transform: scale(0.96);
}

.cfp-qty-input {
    width: 46px;
    text-align: center;
    border-radius: 8px;
    border: 1px solid #d1d1d6;
    padding: 4px;
    font-size: 14px;
}

/* 冰块需求汇总 */
.cfp-ice-summary {
    margin-top: 12px;
    border-top: 1px solid #e5e5ea;
    padding-top: 10px;
}

.cfp-ice-summary-title {
    margin: 0 0 6px;
    font-size: 15px;
}

.cfp-ice-summary-text {
    min-height: 20px;
    font-size: 14px;
    color: #333;
}

.cfp-ice-summary-actions {
    margin-top: 10px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* iPad 前台冰袋强提示容器 */
.cfp-ice-summary-pad {
    border-radius: 12px;
    padding: 10px;
    background-color: #f2f2f7;
    transition: background-color 0.3s ease;
}

/* 冰袋块高亮动画 */
@keyframes cfp-ice-flash-anim {
    0% { background-color: #f2f2f7; }
    25% { background-color: #ffeaa7; }
    50% { background-color: #f2f2f7; }
    75% { background-color: #ffeaa7; }
    100% { background-color: #f2f2f7; }
}

.cfp-ice-flash {
    animation: cfp-ice-flash-anim 1.5s ease-in-out;
}

/* 整页闪烁动画 */
@keyframes cfp-ice-page-flash-anim {
    0% { background-color: #f5f5f7; }
    20% { background-color: #ffeaa7; }
    40% { background-color: #f5f5f7; }
    60% { background-color: #ffeaa7; }
    80% { background-color: #f5f5f7; }
    100% { background-color: #f5f5f7; }
}

.cfp-ice-page-flash {
    animation: cfp-ice-page-flash-anim 1.6s ease-in-out;
}

/* 倒计时区域 */
.cfp-timer-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.cfp-timer-label {
    font-size: 14px;
}

.cfp-timer-input {
    width: 80px;
    border-radius: 8px;
    border: 1px solid #d1d1d6;
    padding: 4px 8px;
    font-size: 14px;
}

.cfp-timer-presets {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 10px;
}

.cfp-timer-presets-label {
    font-size: 13px;
    color: #666;
}

/* 提示音测试块（iPad） */
.cfp-timer-test {
    margin-bottom: 10px;
}

/* 倒计时列表 */
.cfp-timers-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.cfp-timer-empty {
    font-size: 14px;
    color: #999;
}

.cfp-timer-item {
    border-radius: 12px;
    background-color: #f2f2f7;
    padding: 10px 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.cfp-timer-label {
    font-size: 14px;
    font-weight: 600;
}

.cfp-timer-remaining {
    font-size: 18px;
    font-weight: 700;
}

/* iPad 端：开启提示音大遮罩 */
.cfp-sound-gate {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0,0,0,0.4);
    display: flex;
    align-items: center;
    justify-content: center;
}

.cfp-sound-gate-inner {
    max-width: 360px;
    width: 80%;
    background: #ffffff;
    border-radius: 20px;
    padding: 24px 20px 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    text-align: center;
}

.cfp-sound-gate-icon {
    font-size: 36px;
    margin-bottom: 8px;
}

.cfp-sound-gate-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 8px;
}

.cfp-sound-gate-desc {
    font-size: 14px;
    color: #444;
    margin-bottom: 14px;
}

.cfp-sound-gate-tip {
    margin-top: 10px;
    font-size: 12px;
    color: #888;
}

/* iPad：视频弹窗兜底 */
.cfp-video-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: rgba(0,0,0,0.85);
    display: flex;
    align-items: center;
    justify-content: center;
}

.cfp-video-inner {
    max-width: 480px;
    width: 90%;
    background: #000;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.6);
}

.cfp-video-inner video {
    width: 100%;
    height: auto;
    display: block;
}

/* 响应式（大屏） */
@media (min-width: 600px) {
    .cfp-wrapper {
        max-width: 640px;
        padding: 24px;
    }

    .cfp-section-title {
        font-size: 20px;
    }

    .cfp-btn {
        font-size: 16px;
    }

    .cfp-timer-remaining {
        font-size: 20px;
    }
}


/* v2.6 override: 视频弹窗改为右下角悬浮迷你播放窗口 */
.cfp-video-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: transparent;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
}

.cfp-video-inner {
    max-width: 260px;
    width: 60%;
    background: #000;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
    margin: 12px;
}

.cfp-video-inner video {
    width: 100%;
    height: auto;
    display: block;
}
