/* ==================== 1. 设计系统与基础配置 ==================== */
:root {
    --primary-mint: #3ae3b6;
    --primary-mint-light: #d8faf0;
    --primary-mint-dark: #128263;
    --accent-lemon: #ffeb60;
    --accent-coral: #ff6b8b;
    --accent-blue: #54b4ff;
    
    --bg-gradient: linear-gradient(135deg, #eefaf6 0%, #e3f6fd 50%, #f4f6fb 100%);
    --card-bg: rgba(255, 255, 255, 0.78);
    --card-border: rgba(255, 255, 255, 0.6);
    --card-shadow: 0 8px 32px 0 rgba(18, 130, 99, 0.08);
    
    --text-main: #2c3e50;
    --text-muted: #64748b;
    
    --font-heading: 'Noto Sans SC', 'Outfit', sans-serif;
    --font-handwriting: 'Playpen Sans', 'Noto Sans SC', cursive;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent; /* 消除移动端点击蓝色背景 */
}

body {
    font-family: var(--font-heading);
    background: var(--bg-gradient);
    color: var(--text-main);
    min-height: 100dvh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    position: relative;
}

/* ==================== 2. 漂浮气泡背景 (消暑氛围) ==================== */
.bubble-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.bubble {
    position: absolute;
    bottom: -20px;
    background: rgba(58, 227, 182, 0.15);
    border-radius: 50%;
    animation: floatUp 8s infinite linear;
}

.bubble:nth-child(2n) {
    background: rgba(84, 180, 255, 0.12);
}

@keyframes floatUp {
    0% {
        transform: translateY(0) scale(1) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 0.8;
    }
    100% {
        transform: translateY(-110vh) scale(1.3) rotate(360deg);
        opacity: 0;
    }
}

/* ==================== 3. 主容器 ==================== */
.app-container {
    width: 100%;
    max-width: 480px;
    min-height: 100dvh;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    z-index: 10;
}

/* 进度条 */
.progress-bar-container {
    position: fixed;
    top: max(20px, env(safe-area-inset-top));
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 40px);
    max-width: 440px;
    z-index: 100;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

.progress-bar-container.visible {
    opacity: 1;
    pointer-events: all;
}

.progress-line {
    height: 6px;
    background: rgba(58, 227, 182, 0.18);
    border-radius: 10px;
    position: relative;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--primary-mint) 0%, var(--accent-blue) 100%);
    border-radius: 10px;
    transition: width 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

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

.step-dot {
    font-size: 16px;
    opacity: 0.4;
    transform: scale(0.9);
    transition: all 0.3s ease;
}

.step-dot.active {
    opacity: 1;
    transform: scale(1.2);
    filter: drop-shadow(0 2px 8px rgba(58,227,182,0.4));
}

/* ==================== 4. 各屏幕基础配置与切换 ==================== */
.screen {
    display: none;
    width: 100%;
    flex-direction: column;
    justify-content: center;
    animation: slideIn 0.5s cubic-bezier(0.25, 0.8, 0.25, 1) forwards;
}

.screen.active {
    display: flex;
}

@keyframes slideIn {
    0% {
        opacity: 0;
        transform: translateY(30px) scale(0.96);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* ==================== 5. 第一屏：信封互动 (Welcome) ==================== */
#screen-welcome {
    align-items: center;
}

.envelope-wrapper {
    height: 380px;
    perspective: 1000px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: -30px;
}

.envelope {
    position: relative;
    width: 320px;
    height: 220px;
    background: #e9f8f4;
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
    box-shadow: 0 20px 40px rgba(18, 130, 99, 0.12);
    cursor: pointer;
    transition: transform 0.6s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.envelope:not(.open-envelope) {
    animation: envelope-wiggle 3.5s infinite ease-in-out;
    transform-origin: bottom center;
}

.envelope.open-envelope {
    transform: translateY(60px);
}

@keyframes envelope-wiggle {
    0%, 85%, 100% { transform: rotate(0deg) scale(1); }
    87% { transform: rotate(-4deg) scale(1.03); }
    89% { transform: rotate(4deg) scale(1.03); }
    91% { transform: rotate(-3deg) scale(1.02); }
    93% { transform: rotate(3deg) scale(1.02); }
    95% { transform: rotate(-1deg) scale(1.01); }
    97% { transform: rotate(1deg) scale(1.01); }
}

/* 顶部信封口 */
.flap {
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 0;
    border-left: 160px solid transparent;
    border-right: 160px solid transparent;
    border-top: 110px solid var(--primary-mint);
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
    transform-origin: top;
    transition: transform 0.4s ease 0.2s, z-index 0.2s ease 0.2s;
    z-index: 5;
}

.envelope.open-envelope .flap {
    transform: rotateX(180deg);
    z-index: 1;
}

/* 信封前面兜 */
.pocket {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 0;
    border-left: 160px solid #eefbf7;
    border-right: 160px solid #eefbf7;
    border-bottom: 110px solid #e9f8f4;
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
    z-index: 4;
}

.envelope::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 0;
    border-left: 160px solid transparent;
    border-right: 160px solid transparent;
    border-bottom: 110px solid #ddf4ee;
    z-index: 3;
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
}

/* 信纸本体 */
.letter {
    position: absolute;
    left: 15px;
    bottom: 10px;
    width: 290px;
    height: 200px;
    background: #fff;
    border-radius: 6px;
    padding: 18px 15px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.06);
    z-index: 2;
    transition: transform 0.6s cubic-bezier(0.25, 0.8, 0.25, 1) 0.5s, height 0.6s ease 0.5s;
    overflow: hidden;
}

.envelope.open-envelope .letter {
    transform: translateY(-160px);
    height: 300px;
    z-index: 6;
}

.letter-content {
    opacity: 0;
    transition: opacity 0.4s ease 0.8s;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.envelope.open-envelope .letter-content {
    opacity: 1;
}

.letter-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--primary-mint-dark);
    margin-bottom: 10px;
    border-bottom: 1.5px dashed var(--primary-mint-light);
    padding-bottom: 6px;
}

.letter-text {
    font-size: 13.5px;
    line-height: 1.6;
    color: #475569;
}

.letter-buttons {
    display: flex;
    gap: 8px;
    margin-top: 15px;
    position: relative;
    height: 42px;
}

.tap-hint {
    margin-top: 20px;
    font-size: 14px;
    color: var(--primary-mint-dark);
    font-weight: 500;
    animation: pulse 1.5s infinite ease-in-out;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.8; }
    50% { transform: scale(1.05); opacity: 1; }
}

/* ==================== 6. 通用卡片与玻璃拟态 ==================== */
.card-container {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 24px 20px;
    box-shadow: var(--card-shadow);
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.screen-title {
    font-size: 24px;
    font-weight: 900;
    color: var(--primary-mint-dark);
    text-align: center;
}

.screen-subtitle {
    font-size: 14px;
    color: var(--text-muted);
    text-align: center;
    margin-top: -12px;
    line-height: 1.4;
}

/* ==================== 7. 网格选项 (卡片组) ==================== */
.option-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 10px;
}

.option-card {
    background: rgba(255, 255, 255, 0.7);
    border: 2px solid transparent;
    border-radius: 18px;
    padding: 16px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(18,130,99,0.02);
    position: relative;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.option-card:active {
    transform: scale(0.96);
}

.option-card.selected {
    background: var(--primary-mint-light);
    border-color: var(--primary-mint);
    box-shadow: 0 8px 20px rgba(58,227,182,0.18);
    transform: translateY(-2px);
}

.card-icon {
    font-size: 32px;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.06));
}

.card-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-main);
}

.card-desc {
    font-size: 11px;
    color: var(--text-muted);
    line-height: 1.4;
    min-height: 30px;
}

.badge {
    font-size: 9px;
    background: var(--accent-blue);
    color: white;
    padding: 2px 6px;
    border-radius: 10px;
    font-weight: 600;
    position: absolute;
    top: 8px;
    right: 8px;
}

/* 宽屏选项 (大卡片) */
.option-row {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 10px;
}

.option-card-large {
    background: rgba(255, 255, 255, 0.70);
    border: 2px solid transparent;
    border-radius: 20px;
    padding: 20px 16px;
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.02);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.option-card-large:active {
    transform: scale(0.97);
}

.option-card-large.selected {
    background: var(--primary-mint-light);
    border-color: var(--primary-mint);
    box-shadow: 0 8px 24px rgba(58,227,182,0.15);
    transform: translateY(-2px);
}

.option-card-large .card-icon {
    font-size: 40px;
    background: rgba(255,255,255,0.9);
    padding: 10px;
    border-radius: 16px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.04);
}

.option-card-large .card-desc {
    font-size: 12px;
    margin-top: 4px;
    min-height: auto;
}

.large-card-badge {
    position: absolute;
    top: 10px;
    right: 14px;
    font-size: 9px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 8px;
    color: white;
}
.large-card-badge.cool { background: var(--primary-mint-dark); }
.large-card-badge.hot { background: var(--accent-coral); }

/* ==================== 8. 按钮统一样式 ==================== */
.btn {
    font-family: var(--font-heading);
    border: none;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    display: inline-flex;
    justify-content: center;
    align-items: center;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-mint) 0%, #20cfa3 100%);
    color: white;
    box-shadow: 0 4px 14px rgba(32,207,163,0.3);
}

.btn-primary:active {
    transform: scale(0.96);
    box-shadow: 0 2px 6px rgba(32,207,163,0.2);
}

.btn-secondary {
    background: #f1f5f9;
    color: #475569;
}

.letter-buttons .btn {
    flex: 1;
    font-size: 13px;
    padding: 8px 12px;
    border-radius: 10px;
}

/* 拒绝按钮的逃跑动效 */
#btn-reject {
    position: relative;
    z-index: 10;
}

.btn-next {
    width: 100%;
    height: 52px;
    font-size: 16px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--primary-mint) 0%, var(--primary-mint-dark) 100%);
    color: white;
    box-shadow: 0 6px 20px rgba(18,130,99,0.2);
}

.btn-next:disabled {
    background: #e2e8f0;
    color: #94a3b8;
    box-shadow: none;
    cursor: not-allowed;
}

.bottom-action {
    margin-top: 10px;
}

/* ==================== 9. 大转盘弹窗 ==================== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: none;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 28px;
    width: 100%;
    max-width: 380px;
    padding: 24px 20px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.15);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    animation: popUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes popUp {
    0% { transform: scale(0.85); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

.modal-title {
    font-size: 20px;
    font-weight: 800;
    color: var(--text-main);
}

.modal-desc {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.5;
}

.text-hot {
    color: var(--accent-coral) !important;
}

/* 转盘圆盘样式 */
.wheel-container {
    position: relative;
    width: 240px;
    height: 240px;
    margin: 10px 0;
}

.wheel-pointer {
    position: absolute;
    top: -24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    font-size: 32px;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

#wheel-canvas, #drink-wheel-canvas {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 8px solid #2c3e50;
    transition: transform 5s cubic-bezier(0.2, 0.85, 0.25, 1);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
    display: block;
}

/* Tab 切换页样式 */
.tab-container {
    display: flex;
    background: #f1f5f9;
    padding: 4px;
    border-radius: 12px;
    margin-bottom: 8px;
    gap: 4px;
    width: 100%;
}

.tab-btn {
    flex: 1;
    border: none;
    background: transparent;
    padding: 10px 12px;
    font-size: 13px;
    font-weight: 700;
    color: var(--text-muted);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
}

.tab-btn.active {
    background: white;
    color: var(--primary-mint-dark);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.wheel-spin-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 54px;
    height: 54px;
    background: #2c3e50;
    color: white;
    border-radius: 50%;
    border: 4px solid white;
    font-size: 10px;
    font-weight: 900;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    z-index: 8;
}

.wheel-result {
    font-size: 18px;
    font-weight: 800;
    color: var(--primary-mint-dark);
    margin-top: 5px;
}

.modal-actions {
    display: flex;
    gap: 12px;
    width: 100%;
}

.modal-actions .btn {
    flex: 1;
    height: 46px;
    font-size: 14px;
}

/* ==================== 10. 第五屏：精美小票 (Ticket) ==================== */
.ticket-wrapper {
    width: 100%;
    padding: 10px 5px;
    filter: drop-shadow(0 10px 25px rgba(18, 130, 99, 0.15));
}

.ticket {
    background: #ffffff;
    width: 100%;
    padding: 24px 20px;
    position: relative;
    color: #2c3e50;
    font-family: 'Courier New', Courier, monospace; /* 打字机风小票 */
}

/* 小票齿轮效果 */
.ticket-edge {
    position: absolute;
    left: 0;
    width: 100%;
    height: 10px;
    background-size: 16px 10px;
}

.ticket-edge-top {
    top: -9px;
    background-image: linear-gradient(135deg, transparent 50%, #ffffff 50%), linear-gradient(225deg, transparent 50%, #ffffff 50%);
}

.ticket-edge-bottom {
    bottom: -9px;
    background-image: linear-gradient(315deg, transparent 50%, #ffffff 50%), linear-gradient(45deg, transparent 50%, #ffffff 50%);
}

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

.ticket-badge {
    font-family: var(--font-heading);
    font-size: 10px;
    background: #eefbf8;
    color: var(--primary-mint-dark);
    border: 1px solid var(--primary-mint);
    padding: 2px 10px;
    border-radius: 20px;
    font-weight: 700;
}

.ticket-main-title {
    font-family: var(--font-heading);
    font-size: 20px;
    font-weight: 900;
    color: #1a202c;
    margin-top: 8px;
    letter-spacing: 1px;
}

.ticket-serial {
    font-size: 10px;
    color: var(--text-muted);
    margin-top: 4px;
}

.ticket-divider {
    border-top: 1.5px dashed #cbd5e1;
    margin: 14px 0;
}

.ticket-info {
    font-size: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.info-row {
    display: flex;
    justify-content: space-between;
}

.info-label {
    color: #64748b;
    font-weight: bold;
}

.info-value {
    color: #1e293b;
    font-weight: bold;
    font-family: var(--font-heading);
}

.text-highlight {
    color: var(--primary-mint-dark);
    font-size: 14px;
}

.ticket-order {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.order-title, .clauses-title {
    font-family: var(--font-heading);
    font-size: 13px;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 4px;
}

.order-item {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    line-height: 1.5;
}

.item-name {
    color: #64748b;
}

.item-val {
    font-family: var(--font-heading);
    color: #1e293b;
    font-weight: bold;
    text-align: right;
    max-width: 180px;
}

.ticket-clauses {
    font-size: 11px;
    line-height: 1.6;
    color: #475569;
}

.clauses-list {
    padding-left: 16px;
    font-family: var(--font-heading);
    font-weight: 500;
}

.clauses-list li {
    margin-bottom: 4px;
}

.ticket-footer {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

/* 伪条形码 */
.barcode {
    width: 170px;
    height: 38px;
    background: repeating-linear-gradient(
        90deg,
        #1e293b,
        #1e293b 2px,
        transparent 2px,
        transparent 5px,
        #1e293b 5px,
        #1e293b 8px,
        transparent 8px,
        transparent 10px
    );
}

.barcode-num {
    font-size: 9px;
    letter-spacing: 3px;
    color: #64748b;
}

.ticket-thanks {
    font-family: var(--font-handwriting);
    font-size: 13px;
    font-weight: 700;
    color: var(--accent-coral);
    margin-top: 8px;
}

.ticket-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 20px;
}

.ticket-actions .btn {
    height: 50px;
    font-size: 15px;
    border-radius: 14px;
}

.btn-restart {
    background: transparent;
    color: var(--primary-mint-dark);
    border: 2px solid var(--primary-mint);
}

/* ==================== 11. 截图保存弹窗 & Toast ==================== */
.toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(30px);
    background: rgba(15, 23, 42, 0.85);
    color: white;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 13px;
    font-weight: 600;
    z-index: 2000;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.toast.active {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.image-preview-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1500;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: none;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.image-preview-modal.active {
    display: flex;
}

.preview-content {
    background: white;
    border-radius: 28px;
    width: 100%;
    max-width: 400px;
    padding: 24px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.25);
    animation: popUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.preview-title {
    font-size: 18px;
    font-weight: 800;
    color: var(--primary-mint-dark);
}

.preview-desc {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: -8px;
}

.preview-image-container {
    width: 100%;
    max-height: calc(80dvh - 160px);
    overflow-y: auto;
    border-radius: 12px;
    border: 2px dashed var(--primary-mint-light);
    padding: 4px;
    background: #f8fafc;
}

.preview-image-container img {
    width: 100%;
    display: block;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

/* ==================== 11.5 子路线列表样式 ==================== */
.sub-routes-group {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1.5px dashed var(--primary-mint-light);
    animation: slideIn 0.4s ease forwards;
    width: 100%;
    text-align: left;
}

.sub-routes-title {
    font-size: 13.5px;
    font-weight: 800;
    color: var(--primary-mint-dark);
    margin-bottom: 12px;
}

.sub-routes-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.route-card {
    background: rgba(255, 255, 255, 0.7);
    border: 1.5px solid transparent;
    border-radius: 14px;
    padding: 12px 14px;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.02);
    transition: all 0.3s ease;
}

.route-card:active {
    transform: scale(0.98);
}

.route-card.selected {
    background: var(--primary-mint-light);
    border-color: var(--primary-mint);
    box-shadow: 0 4px 12px rgba(58,227,182,0.12);
}

.route-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
}

.route-emoji {
    font-size: 18px;
}

.route-name {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-main);
}

.route-desc {
    font-size: 11px;
    color: var(--text-muted);
    line-height: 1.4;
    margin-top: 5px;
}

/* ==================== 12. 响应式布局优化 (针对极小屏设备) ==================== */
@media (max-width: 360px) {
    .app-container {
        padding: 12px;
    }
    
    .envelope {
        width: 280px;
        height: 190px;
    }
    
    .flap {
        border-left-width: 140px;
        border-right-width: 140px;
        border-top-width: 95px;
    }
    
    .pocket {
        border-left-width: 140px;
        border-right-width: 140px;
        border-bottom-width: 95px;
    }
    
    .envelope::before {
        border-left-width: 140px;
        border-right-width: 140px;
        border-bottom-width: 95px;
    }
    
    .letter {
        width: 250px;
        height: 170px;
        left: 15px;
    }
    
    .envelope.open-envelope .letter {
        transform: translateY(-135px);
        height: 260px;
    }
    
    .screen-title {
        font-size: 20px;
    }
    
    .option-grid {
        gap: 8px;
    }
    
    .option-card {
        padding: 12px 8px;
    }
    
    .card-icon {
        font-size: 26px;
    }
    
    .card-title {
        font-size: 13px;
    }
    
    .card-desc {
        font-size: 10px;
        min-height: 24px;
    }
    
    .btn-next {
        height: 46px;
        font-size: 15px;
    }
}

/* ==================== 见面时间选择器 ==================== */
.time-selector-section {
    margin-top: 20px;
    width: 100%;
    animation: fadeInUp 0.5s ease-out;
}

.time-selector-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.time-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 12px;
}

.time-chip {
    border: 2px solid #e2e8f0;
    background: white;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 700;
    color: #475569;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.time-chip:hover {
    border-color: #cbd5e1;
    transform: translateY(-1px);
}

.time-chip.selected {
    border-color: var(--primary-pink);
    background: #fff5f7;
    color: var(--primary-pink);
    box-shadow: 0 4px 12px rgba(255, 107, 139, 0.15);
}

.custom-time-input-container {
    display: none;
    justify-content: center;
    margin-bottom: 12px;
}

.custom-time-input {
    padding: 8px 12px;
    border: 2px solid var(--primary-pink);
    border-radius: 8px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    color: var(--text-color);
    outline: none;
    background: #fff8f9;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.02);
}
