/* ==========================================================================
   前台登记系统 · 小程序风格设计系统（全站公共样式）
   设计语言：简洁 / 直观 / 易用，卡片化、柔和阴影、大触控区域
   适配：PC 各分辨率 / 平板 / 各类手机（含 iPhone 安全区）
   说明：保留历史类名（.container/.form-group/.btn 等）作为兼容层，
         JS 依赖的 id 与类名均不变。
   ========================================================================== */

/* ------------------------------ 设计令牌 -------------------------------- */
:root {
    /* 品牌主色 */
    --primary: #2563EB;
    --primary-hover: #1D4ED8;
    --primary-active: #1E40AF;
    --primary-light: #EFF6FF;
    --primary-ring: rgba(37, 99, 235, 0.16);

    /* 语义色 */
    --success: #10B981;
    --success-dark: #059669;
    --success-light: #ECFDF5;
    --warning: #F59E0B;
    --warning-dark: #B45309;
    --warning-light: #FFFBEB;
    --danger: #EF4444;
    --danger-dark: #DC2626;
    --danger-light: #FEF2F2;

    /* 背景与表面 */
    --bg: #F6F7F9;
    --surface: #FFFFFF;
    --surface-2: #F8FAFC;
    --surface-3: #F1F5F9;

    /* 文本 */
    --text: #1F2937;
    --text-2: #4B5563;
    --text-3: #9CA3AF;

    /* 边框 */
    --border: #EBEDF0;
    --border-strong: #DCDFE6;

    /* 圆角 */
    --r-sm: 8px;
    --r: 12px;
    --r-lg: 16px;
    --r-pill: 999px;

    /* 阴影 */
    --shadow-xs: 0 1px 2px rgba(16, 24, 40, 0.04);
    --shadow-sm: 0 2px 8px rgba(16, 24, 40, 0.05);
    --shadow: 0 6px 20px rgba(16, 24, 40, 0.07);
    --shadow-lg: 0 16px 40px rgba(16, 24, 40, 0.14);

    /* iPhone 底部安全区 */
    --safe-bottom: env(safe-area-inset-bottom, 0px);
    --safe-top: env(safe-area-inset-top, 0px);

    --transition: 0.2s ease;
}

/* ------------------------------ 基础重置 -------------------------------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
                 "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    font-size: 15px;
    line-height: 1.6;
    color: var(--text);
    background-color: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    word-break: break-word;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: var(--primary);
    text-decoration: none;
}

ul, ol {
    list-style: none;
}

h1, h2, h3, h4 {
    font-weight: 600;
    line-height: 1.35;
}

/* ------------------------------ 页面容器 -------------------------------- */
.container {
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
    min-height: 100vh;
}

/* 首页等需要更宽的容器 */
.container--wide {
    max-width: 960px;
}

/* 页面顶部标题（小程序导航栏式） */
.page-title {
    text-align: center;
    font-size: 19px;
    font-weight: 600;
    color: var(--text);
    margin: 20px 0 18px;
}

.page-subtitle {
    text-align: center;
    color: var(--text-3);
    font-size: 13px;
    margin-top: -10px;
    margin-bottom: 20px;
}

/* 表单页引导语（置于幻灯片与首个卡片之间，兼作留白） */
.form-lead {
    text-align: center;
    color: var(--text-3);
    font-size: 13px;
    margin: 16px 0 14px;
}

/* -------------------------- 小程序式导航栏 ------------------------------ */
/* 吸顶半透明毛玻璃标题栏：左侧返回、居中标题（沿用微信小程序导航栏观感） */
.mp-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.9);
    -webkit-backdrop-filter: saturate(180%) blur(14px);
    backdrop-filter: saturate(180%) blur(14px);
    border-bottom: 1px solid var(--border);
    padding-top: var(--safe-top);
}

.mp-nav__inner {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
    height: 46px;
    display: flex;
    align-items: center;
    padding: 0 6px;
}

.mp-nav__title {
    position: absolute;
    left: 56px;
    right: 56px;
    text-align: center;
    font-size: 17px;
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    pointer-events: none;
}

.mp-nav__back {
    position: relative;
    z-index: 1;
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--r-pill);
    color: var(--text);
    transition: background var(--transition);
}

.mp-nav__back:hover {
    background: var(--surface-3);
}

.mp-nav__back:active {
    background: var(--border);
}

.mp-nav__back svg {
    width: 22px;
    height: 22px;
    display: block;
}

/* 通用白色卡片 */
.card,
.panel {
    background: var(--surface);
    border-radius: var(--r-lg);
    padding: 22px;
    box-shadow: var(--shadow-sm);
}

/* ------------------------------ 幻灯片 ---------------------------------- */
.slideshow {
    position: relative;
    width: 100%;
    height: 300px;
    border-radius: var(--r-lg);
    overflow: hidden;
    background: var(--surface-3);
    box-shadow: var(--shadow-sm);
}

/* 首页大 Banner */
.slideshow--banner {
    height: 420px;
}

.slideshow-container,
.slideshow-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
}

/* 两套历史命名等价处理：.slide / .slide-item */
.slide,
.slide-item {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.45s ease-in-out;
    will-change: opacity;
}

.slide.active,
.slide-item.active {
    opacity: 1;
    visibility: visible;
}

.slide img,
.slide-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* 左右切换按钮（默认隐藏，PC 悬停显示） */
.slideshow-controls {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    padding: 0 16px;
    z-index: 5;
    opacity: 0;
    transition: opacity var(--transition);
}

.slideshow:hover .slideshow-controls {
    opacity: 1;
}

.slideshow-btn {
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.45);
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(6px);
    transition: background var(--transition), transform var(--transition);
}

.slideshow-btn:hover {
    background: rgba(0, 0, 0, 0.7);
    transform: scale(1.06);
}

/* 指示点：胶囊式（两套历史命名等价） */
.slideshow-dots,
.slide-nav {
    position: absolute;
    bottom: 14px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 7px;
    z-index: 5;
}

.dot,
.slide-nav-btn {
    width: 8px;
    height: 8px;
    padding: 0;
    border: none;
    border-radius: var(--r-pill);
    background: rgba(255, 255, 255, 0.55);
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active,
.slide-nav-btn.active {
    width: 22px;
    background: #fff;
}

/* 行内输入 + 按钮（短信验证码组） */
.field-row {
    display: flex;
    gap: 10px;
}
.field-row > input,
.field-row > .field-row__main {
    flex: 1;
    min-width: 0;
}
.field-row > .btn {
    flex-shrink: 0;
}

/* ------------------------------ 表单 ------------------------------------ */
.form-group {
    margin-bottom: 20px;
}

.form-group label,
label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
}

input[type="text"],
input[type="tel"],
input[type="email"],
input[type="number"],
input[type="password"],
select,
textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--border-strong);
    border-radius: var(--r-sm);
    background: var(--surface);
    font-size: 16px;               /* ≥16px 防止 iOS 聚焦自动放大 */
    color: var(--text);
    font-family: inherit;
    transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
}

textarea {
    resize: vertical;
    min-height: 96px;
}

select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%239CA3AF' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 40px;
    cursor: pointer;
}

input::placeholder,
textarea::placeholder {
    color: var(--text-3);
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-ring);
}

/* 错误态输入框（JS 可能加内联样式，此处提供类方式） */
input.is-invalid,
textarea.is-invalid,
select.is-invalid {
    border-color: var(--danger);
    background: var(--danger-light);
}

/* ------------------------------ 表单分区（卡片组） --------------------- */
.form-section {
    background: var(--surface);
    border-radius: var(--r-lg);
    padding: 20px 20px 4px;
    box-shadow: var(--shadow-xs);
    margin-bottom: 14px;
    border: 1px solid transparent;
    transition: box-shadow var(--transition), border-color var(--transition);
    animation: mp-rise 0.36s ease both;
}

/* 卡片依次浮入（营造小程序的层次感，间隔很轻） */
.form-section:nth-child(1) { animation-delay: 0.02s; }
.form-section:nth-child(2) { animation-delay: 0.08s; }
.form-section:nth-child(3) { animation-delay: 0.14s; }
.form-section:nth-child(4) { animation-delay: 0.2s; }

/* 聚焦时卡片轻微抬升，形成"正在填写这一块"的反馈 */
.form-section:focus-within {
    box-shadow: var(--shadow-sm);
    border-color: var(--primary-light);
}

@keyframes mp-rise {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.form-section__title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 16px;
}

.form-section__title::before {
    content: "";
    width: 4px;
    height: 15px;
    border-radius: 2px;
    background: var(--primary);
}

.form-section .form-group:last-child {
    margin-bottom: 16px;
}

.form-submit-bar {
    margin: 22px 0 8px;
}

/* ------------------------------ 多选/单选 ------------------------------- */
.checkbox-group,
.radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 4px;
}

.checkbox-item,
.radio-item {
    position: relative;
    display: flex;
    align-items: center;
    gap: 7px;
    flex: 1 1 calc(50% - 10px);
    min-width: 130px;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: var(--r-sm);
    background: var(--surface);
    font-size: 14px;
    cursor: pointer;
    transition: all var(--transition);
    user-select: none;
}

.checkbox-item:hover,
.radio-item:hover {
    border-color: var(--primary);
    background: var(--primary-light);
}

.checkbox-item input[type="checkbox"],
.checkbox-item input[type="radio"],
.radio-item input[type="radio"] {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    accent-color: var(--primary);
    cursor: pointer;
}

/* 选中态（现代浏览器 :has；不支持时由 accent-color 的勾选框表达状态） */
.checkbox-item:has(input:checked),
.radio-item:has(input:checked) {
    border-color: var(--primary);
    background: var(--primary-light);
    color: var(--primary-active);
    font-weight: 500;
}

/* ------------------------------ 按钮 ------------------------------------ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 46px;
    padding: 0 22px;
    border: none;
    border-radius: var(--r-sm);
    background: var(--primary);
    color: #fff;
    font-size: 16px;
    font-weight: 500;
    font-family: inherit;
    line-height: 1.2;
    cursor: pointer;
    text-align: center;
    transition: background var(--transition), transform var(--transition), box-shadow var(--transition), opacity var(--transition);
}

.btn:hover {
    background: var(--primary-hover);
}

.btn:active {
    background: var(--primary-active);
    transform: scale(0.985);
}

.btn:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px var(--primary-ring);
}

.btn:disabled,
.btn[disabled] {
    background: var(--border-strong);
    color: #fff;
    cursor: not-allowed;
    transform: none;
}

/* 块级按钮（表单提交主按钮） */
.btn-block {
    display: flex;
    width: 100%;
}

/* 次要按钮：白底描边 */
.btn-secondary {
    background: var(--surface);
    color: var(--text-2);
    border: 1px solid var(--border-strong);
}
.btn-secondary:hover {
    background: var(--surface-2);
    color: var(--text);
}
.btn-secondary:active {
    background: var(--surface-3);
}
.btn-secondary:disabled {
    background: var(--surface-2);
    color: var(--text-3);
    border-color: var(--border);
}

/* 弱按钮（仅文字感） */
.btn-ghost {
    background: transparent;
    color: var(--text-2);
}
.btn-ghost:hover {
    background: var(--surface-3);
}

/* 小尺寸（用于行内验证码等） */
.btn-sm {
    min-height: 38px;
    padding: 0 16px;
    font-size: 14px;
}

/* 按钮组（成功页底部） */
.btn-group {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}
.btn-group .btn {
    flex: 1;
}

/* ------------------------------ 提示文案 -------------------------------- */
.error {
    display: block;
    margin-top: 6px;
    color: var(--danger);
    font-size: 13px;
    line-height: 1.5;
    min-height: 0;
}

.success {
    display: block;
    margin-top: 6px;
    color: var(--success-dark);
    font-size: 13px;
}

.required {
    color: var(--danger);
    margin-left: 2px;
}

.note {
    margin-top: 7px;
    font-size: 12px;
    color: var(--text-3);
    line-height: 1.5;
}

/* 警示条（参展注意事项等） */
.warning,
.attention {
    background: var(--warning-light);
    border: 1px solid #FDE68A;
    border-radius: var(--r-sm);
    padding: 14px 16px;
    margin: 20px 0;
    color: var(--warning-dark);
    font-size: 13px;
}

.warning h3,
.attention h3 {
    font-size: 14px;
    margin-bottom: 8px;
}

.attention ul {
    padding-left: 18px;
    list-style: disc;
}
.attention li {
    margin-bottom: 5px;
    color: var(--warning-dark);
}

/* ------------------------------ 首页入口卡 ------------------------------ */
.entry-hero {
    text-align: center;
    margin: 26px 0 22px;
}

.entry-hero h1 {
    font-size: 22px;
    color: var(--text);
    margin-bottom: 8px;
}

.entry-hero p {
    color: var(--text-3);
    font-size: 14px;
}

.entry-grid {
    display: flex;
    gap: 18px;
}

.options {
    display: flex;
    gap: 18px;
}

.option-card,
.entry-card {
    position: relative;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 28px 20px 24px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-xs);
    cursor: pointer;
    text-align: center;
    overflow: hidden;
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.option-card:hover,
.entry-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary);
    box-shadow: var(--shadow);
}

.option-card:active,
.entry-card:active {
    transform: translateY(-1px) scale(0.99);
}

.option-card .entry-icon,
.entry-card .entry-icon {
    width: 58px;
    height: 58px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-light);
    color: var(--primary);
    font-size: 28px;
    margin-bottom: 14px;
}

.option-card h2,
.entry-card h2 {
    font-size: 17px;
    color: var(--text);
    margin-bottom: 6px;
}

.option-card p,
.entry-card p {
    color: var(--text-3);
    font-size: 13px;
    margin-bottom: 16px;
}

.option-card .btn {
    min-height: 40px;
    padding: 0 24px;
    font-size: 14px;
}

/* ------------------------------ 首页查询面板 ---------------------------- */
.search-section,
.search-panel {
    margin-top: 26px;
    background: var(--surface);
    border-radius: var(--r-lg);
    padding: 24px;
    box-shadow: var(--shadow-sm);
}

.search-header {
    margin-bottom: 18px;
}

.search-header h3 {
    font-size: 17px;
    color: var(--text);
}

/* 行内表单项（首页查询） */
.form-row {
    display: flex;
    gap: 12px;
    align-items: flex-end;
}
.form-row .form-group {
    flex: 1;
    margin-bottom: 0;
}

/* ------------------------------ 成功页 ---------------------------------- */
.result-hero,
.success-message {
    text-align: center;
    padding: 22px 20px;
    margin-bottom: 22px;
    background: var(--success-light);
    border-radius: var(--r);
}

.result-hero h2,
.success-message h2 {
    font-size: 19px;
    color: var(--success-dark);
    margin-bottom: 6px;
}

.result-hero p,
.success-message p {
    color: var(--text-2);
    font-size: 14px;
}

/* 大圆形成功图标 */
.success-icon-circle {
    width: 76px;
    height: 76px;
    margin: 8px auto 16px;
    border-radius: 50%;
    background: var(--success);
    color: #fff;
    font-size: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.3);
}

/* 简易勾号（参展成功页历史类名） */
.success-icon {
    width: 76px;
    height: 76px;
    margin: 0 auto 18px;
    border-radius: 50%;
    background: var(--success);
    color: #fff;
    font-size: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.3);
}

/* 登记信息摘要 */
.company-info {
    text-align: center;
    margin: 20px 0;
    font-size: 14px;
    color: var(--text-2);
}

.company-info .company-name {
    font-size: 18px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 4px;
}

/* 二维码卡片 */
.qr-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 24px 0;
}

.qr-wrapper {
    position: relative;
    padding: 14px;
    background: var(--surface);
    border-radius: var(--r);
    box-shadow: var(--shadow-sm);
}

.qr-glow {
    position: absolute;
    inset: -8px;
    border-radius: var(--r-lg);
    background: linear-gradient(45deg, var(--primary), var(--success), var(--primary));
    background-size: 300% 300%;
    animation: qr-glow-move 3s ease-in-out infinite;
    z-index: -1;
    opacity: 0.55;
}

@keyframes qr-glow-move {
    0%   { background-position: 0% 50%; }
    50%  { background-position: 100% 50%; opacity: 0.85; }
    100% { background-position: 0% 50%; }
}

/* 留言区 */
.note-section {
    margin-top: 26px;
}
.note-section h3 {
    font-size: 15px;
    margin-bottom: 10px;
}

/* 成功页容器改为卡片观感（保留 .container 历史结构） */
.success-page .container {
    margin-top: 30px;
    margin-bottom: 30px;
    min-height: 0;
    background: var(--surface);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-sm);
}

.contact-tip {
    font-size: 15px;
    color: var(--text-2);
    margin: 24px 0;
}

/* ------------------------------ 信息页（扫码后） ------------------------ */
.info-page .container {
    max-width: 640px;
    padding: 0;
    overflow: hidden;
    background: var(--surface);
    border-radius: var(--r-lg);
    margin-top: 30px;
    margin-bottom: 30px;
    min-height: 0;
    box-shadow: var(--shadow-sm);
}

.info-hero,
.info-page .header {
    background: linear-gradient(135deg, #2563EB 0%, #1D4ED8 100%);
    color: #fff;
    padding: 26px 28px;
    text-align: center;
}

.info-hero h1,
.info-page .header h1 {
    font-size: 20px;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.info-hero .sub,
.info-page .header .sub {
    margin-top: 6px;
    font-size: 13px;
    opacity: 0.85;
}

.info-page .body {
    padding: 22px 26px 8px;
}

.reg-no {
    text-align: center;
    background: var(--primary-light);
    border: 1px dashed #93C5FD;
    border-radius: var(--r-sm);
    padding: 14px;
    margin-bottom: 20px;
}

.reg-no .label {
    font-size: 13px;
    color: var(--primary);
}

.reg-no .value {
    margin-top: 4px;
    font-size: 23px;
    font-weight: 700;
    color: var(--primary-active);
    letter-spacing: 1.5px;
    word-break: break-all;
}

.info-list li {
    display: flex;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
    font-size: 15px;
}

.info-list li:last-child {
    border-bottom: none;
}

.info-list .k {
    flex: 0 0 92px;
    color: var(--text-3);
}

.info-list .v {
    flex: 1;
    color: var(--text);
    word-break: break-all;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tag {
    display: inline-block;
    padding: 2px 11px;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: var(--r-pill);
    font-size: 13px;
}

.mask-hint {
    margin: 16px 0 6px;
    padding: 10px 13px;
    background: var(--warning-light);
    border: 1px solid #FDE68A;
    border-radius: var(--r-sm);
    color: var(--warning-dark);
    font-size: 13px;
}

.info-page .footer {
    padding: 16px 26px 22px;
    text-align: center;
    color: var(--text-3);
    font-size: 12px;
}

/* 加载/错误状态 */
.state {
    padding: 56px 26px;
    text-align: center;
    color: var(--text-3);
    font-size: 15px;
}

.state .icon {
    font-size: 40px;
    margin-bottom: 12px;
}

.state.error {
    color: var(--danger-dark);
}

.state.error .icon {
    color: var(--danger);
}

.state button {
    margin-top: 16px;
    min-height: 40px;
    padding: 0 22px;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: var(--r-sm);
    font-size: 14px;
    cursor: pointer;
}
.state button:hover { background: var(--primary-hover); }

/* ------------------------------ 查询结果卡 ------------------------------ */
.result-card {
    margin-top: 18px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    padding: 20px;
    box-shadow: var(--shadow-xs);
    animation: result-in 0.4s ease;
}

@keyframes result-in {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.result-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 14px;
    margin-bottom: 14px;
    border-bottom: 1px solid var(--border);
}

.result-header h3 {
    font-size: 16px;
}

.badge {
    display: inline-block;
    padding: 3px 11px;
    border-radius: var(--r-pill);
    background: var(--success);
    color: #fff;
    font-size: 12px;
}

.result-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
    margin-bottom: 18px;
}

.result-grid .info-row {
    display: flex;
    font-size: 14px;
}

.result-grid .info-row strong {
    flex: 0 0 64px;
    color: var(--text-3);
    font-weight: 400;
}

.qr-section {
    text-align: center;
    background: var(--surface-2);
    border-radius: var(--r-sm);
    padding: 20px;
}

.qr-section h4 {
    font-size: 14px;
    color: var(--text-2);
    margin-bottom: 12px;
}

.qr-code {
    display: inline-block;
    background: #fff;
    padding: 10px;
    border-radius: var(--r-sm);
}

.qr-hint {
    font-size: 12px;
    color: var(--text-3);
    margin-top: 10px;
}

.back-link {
    text-align: center;
    margin-top: 22px;
}
.back-link a {
    color: var(--text-3);
    font-size: 14px;
}

/* -------------------- 首页「已登记查询」视觉增强 ------------------------ */
/* 说明：以下规则均限定在 .search-section / .search-record / .search-* 命名空间内，
   不影响其他页面（visitor-search.html 等）既有的样式与结构。 */

/* 查询面板：顶部渐变描边 + 图标化标题 */
.search-section {
    position: relative;
    overflow: hidden;
}

.search-section::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), #60A5FA 55%, rgba(96, 165, 250, 0));
}

.search-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.search-header__icon {
    flex-shrink: 0;
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 11px;
    background: var(--primary-light);
    color: var(--primary);
}

.search-header__text {
    min-width: 0;
}

.search-header .note {
    margin-top: 4px;
}

/* 验证码行：按钮文字不换行 */
.search-section .field-row > .btn {
    white-space: nowrap;
}

/* 结果汇总条 */
.search-summary {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 4px 10px;
    margin-top: 18px;
    padding: 12px 16px;
    border-radius: var(--r-sm);
    background: var(--primary-light);
    color: var(--primary);
    font-size: 14px;
}

.search-summary__count {
    font-size: 20px;
    font-weight: 700;
    line-height: 1;
}

.search-summary__phone {
    margin-left: auto;
    font-size: 12px;
    color: var(--text-2);
}

/* 结果卡：按登记类型着色模块标题（--accent 由修饰类注入） */
.search-record--visitor   { --accent: #E60012; }   /* 专业观众：票面红（对齐成功页） */
.search-record--channel   { --accent: #F59E0B; }   /* 选品渠道：琥珀 */
.search-record--exhibitor { --accent: #7C3AED; }   /* 参展商：紫 */

.search-record {
    margin-top: 22px;
    animation: result-in 0.45s ease both;
}

/* 模块标题 + 状态徽标（标题风格对齐成功页 .audience-title 票面分类） */
.search-record__head {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 12px;
}

.search-record__title {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 3px;
    color: var(--accent, var(--primary));
}

/* 票卡：字号、间距、圆角、阴影与报名成功页 .ticket-card 保持一致 */
.search-ticket {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-sm);
    padding: 18px;
}

.search-ticket__main {
    display: flex;
    align-items: center;
    gap: 16px;
}

.search-ticket__info {
    flex: 1 1 auto;
    min-width: 0;
}

.sti-name {
    font-size: 20px;
    font-weight: 700;
    color: var(--text);
    line-height: 1.3;
    word-break: break-all;
}

/* 字段行：标签列 + 值列 两栏对齐，换行时值内容与值列左缘对齐，不再错位 */
.sti-line {
    display: grid;
    grid-template-columns: minmax(4.4em, auto) minmax(0, 1fr);
    column-gap: 8px;
    margin-top: 6px;
    font-size: 14.5px;
    color: var(--text-2);
    line-height: 1.5;
}

.sti-k {
    color: var(--text-3);
    white-space: nowrap;
}

/* 值列：优先按词语/空格边界折行，超长不可断词（邮箱、证件号等）再整体断行，避免逐字错位 */
.sti-v {
    min-width: 0;
    overflow-wrap: break-word;
    word-break: normal;
}

/* 专属二维码：动态描边光圈（蓝绿橙渐变，与成功页一致；search- 前缀命名隔离） */
.search-ticket__qr {
    flex: 0 0 auto;
}

.search-qr-stage {
    position: relative;
    width: 148px;
    isolation: isolate;
}

.search-qr-halo {
    position: absolute;
    inset: -12px;
    border-radius: 26px;
    z-index: 0;
    background: linear-gradient(120deg, #38BDF8, #10B981, #F59E0B, #38BDF8);
    background-size: 300% 300%;
    filter: blur(14px);
    opacity: 0.5;
    animation: search-qr-flow 5s linear infinite, search-qr-breathe 3.6s ease-in-out infinite;
}

.search-qr-ring {
    position: absolute;
    inset: -4px;
    border-radius: 18px;
    z-index: 1;
    background: linear-gradient(120deg, #38BDF8, #10B981, #F59E0B, #38BDF8);
    background-size: 300% 300%;
    animation: search-qr-flow 3.2s linear infinite;
    box-shadow: 0 0 14px rgba(56, 189, 248, 0.5), 0 0 22px rgba(16, 185, 129, 0.35), 0 0 30px rgba(245, 158, 11, 0.3);
}

.search-qr-frame {
    position: relative;
    z-index: 2;
    background: #fff;
    border-radius: 14px;
    padding: 7px;
    box-shadow: 0 4px 14px rgba(16, 24, 40, 0.06);
}

/* 二维码自适应填充（库生成 canvas/img 等比缩放，不溢出） */
.search-qr-frame canvas,
.search-qr-frame img {
    width: 100% !important;
    height: auto !important;
    display: block;
}

@keyframes search-qr-flow {
    0%   { background-position: 0% 50%; }
    100% { background-position: 200% 50%; }
}

@keyframes search-qr-breathe {
    0%, 100% { opacity: 0.42; }
    50%      { opacity: 0.78; }
}

/* 编号（预登记号 / 渠道号码 / 登记编号，样式对齐成功页 .ticket-regno） */
.search-ticket__regno {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px dashed var(--border-strong);
    text-align: center;
    font-size: 15px;
    color: var(--text-2);
}

.search-ticket__regno .value {
    color: var(--primary);
    font-size: 20px;
    font-weight: 800;
    letter-spacing: 1.5px;
    word-break: break-all;
}

/* 底部文字提醒（保留原有内容与展示逻辑：存在二维码时展示） */
.search-qr-hint {
    margin-top: 12px;
    text-align: center;
    font-size: 12px;
    color: var(--text-3);
}

/* 空状态 */
.search-empty {
    text-align: center;
    padding: 30px 20px 26px;
}

.search-empty__icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 14px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--surface-3);
    color: var(--text-3);
}

.search-empty h3 {
    font-size: 16px;
    color: var(--text);
    margin-bottom: 6px;
}

.search-empty p {
    font-size: 13px;
    color: var(--text-3);
    line-height: 1.6;
}

/* ---------------- 首页「已登记查询」移动端适配 ---------------- */
@media (max-width: 768px) {
    .search-section {
        padding: 18px;
    }
}

@media (max-width: 480px) {
    .search-header__icon {
        width: 34px;
        height: 34px;
        border-radius: 10px;
    }

    .search-section {
        padding: 16px 14px;
    }

    .search-summary {
        padding: 11px 14px;
    }

    /* 票卡在窄屏收窄内边距、字号与二维码尺寸，保持与成功页一致的缩放策略 */
    .search-record__title {
        font-size: 18px;
        letter-spacing: 2px;
    }

    .search-ticket {
        padding: 14px;
    }

    /* 窄屏：信息与二维码改上下排布，字段获得整行宽度，长文本（证件号/邮箱/登记时间）不再折断错位 */
    .search-ticket__main {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }

    .search-ticket__qr {
        align-self: center;
    }

    .sti-name { font-size: 18px; }
    .sti-line { font-size: 13.5px; }

    .search-qr-stage { width: 132px; }

    .search-ticket__regno { font-size: 14px; }
    .search-ticket__regno .value { font-size: 18px; }
}

@media (max-width: 360px) {
    .search-qr-stage { width: 118px; }
}

/* ------------------------ 渠道页：报名成功弹窗 -------------------------- */
.success-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.55);
    z-index: 1000;
    padding: 20px;
}

.success-content {
    width: 100%;
    max-width: 460px;
    max-height: 90vh;
    overflow-y: auto;
    background: var(--surface);
    border-radius: var(--r-lg);
    padding: 28px 26px;
    text-align: center;
    box-shadow: var(--shadow-lg);
}

.success-content h2 {
    font-size: 20px;
    color: var(--success-dark);
    margin-bottom: 14px;
}

.success-content p {
    font-size: 14px;
    color: var(--text-2);
    margin-bottom: 12px;
}

.success-content .company-info {
    text-align: left;
    background: var(--surface-2);
    border-radius: var(--r-sm);
    padding: 16px;
    margin: 16px 0;
}

.success-content .company-info .company-name {
    font-size: 17px;
}

.success-content .qr-code-section {
    background: transparent;
    margin: 8px 0;
}

.success-content .qr-code-section img {
    max-width: 150px;
    margin: 0 auto;
    border-radius: var(--r-sm);
}

.success-content .btn {
    margin-top: 14px;
}

.权益-link {
    color: var(--primary);
    font-weight: 500;
}
.权益-link:hover { text-decoration: underline; }

#modalQrCode {
    width: 190px;
    height: 190px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border-radius: var(--r-sm);
    padding: 8px;
}

#modalQrCode canvas,
#modalQrCode img {
    max-width: 100%;
    max-height: 100%;
    border-radius: 4px;
}

/* ------------------------------ 隐私弹窗 -------------------------------- */
.modal-sheet {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.55);
    z-index: 9999;
    padding: 20px;
}

.modal-sheet__dialog {
    width: 100%;
    max-width: 720px;
    max-height: 86vh;
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border-radius: var(--r-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.modal-sheet__title {
    padding: 16px 22px;
    border-bottom: 1px solid var(--border);
    font-size: 16px;
    font-weight: 600;
}

.modal-sheet__body {
    flex: 1;
    overflow: hidden;
    min-height: 120px;
}

.modal-sheet__body iframe {
    width: 100%;
    height: 56vh;
    border: none;
}

.modal-sheet__footer {
    padding: 14px 22px calc(14px + var(--safe-bottom));
    border-top: 1px solid var(--border);
}

/* ------------------------------ 页脚 ------------------------------------ */
.site-footer {
    text-align: center;
    padding: 22px 14px calc(22px + var(--safe-bottom));
    color: var(--text-3);
    font-size: 12px;
    line-height: 2;
    background: var(--surface);
    border-top: 1px solid var(--border);
    margin-top: 30px;
}

.site-footer a {
    color: var(--text-3);
}

.site-footer a:hover {
    color: var(--primary);
}

/* ==========================================================================
   响应式适配
   ========================================================================== */

/* ---------- 大屏 PC（≥1200px）：首页卡片更大、表单居中 ---------- */
@media (min-width: 1200px) {
    .container--wide {
        max-width: 1040px;
    }
    .slideshow--banner {
        height: 460px;
    }
}

/* ---------- 平板/小 PC（≤1024px）：首页三卡保持横向但收窄 ---------- */
@media (max-width: 1024px) {
    .container--wide {
        max-width: 760px;
    }
}

/* ---------- 手机大横屏/小平板（≤900px）：入口卡纵向堆叠 ---------- */
@media (max-width: 900px) {
    .options,
    .entry-grid {
        flex-direction: column;
    }
    .option-card,
    .entry-card {
        flex-direction: row;
        align-items: center;
        text-align: left;
        padding: 20px;
        gap: 16px;
    }
    .option-card .entry-icon,
    .entry-card .entry-icon {
        margin-bottom: 0;
        flex-shrink: 0;
    }
    .option-card .card-text,
    .entry-card .card-text {
        flex: 1;
    }
    .option-card p,
    .entry-card p {
        margin-bottom: 0;
    }
    .option-card .btn,
    .entry-card .btn {
        flex-shrink: 0;
    }
    .container--wide {
        max-width: 600px;
    }
}

/* ---------- 手机（≤768px） ---------- */
@media (max-width: 768px) {
    body {
        font-size: 15px;
    }

    /* 容器：手机上去掉两侧留白与全高背景，内容贴边铺满 */
    .container {
        padding: 14px;
    }

    /* 幻灯片全出血（含 form 页负 margin 方案，只在窄容器页面生效） */
    .slideshow {
        height: 240px;
        border-radius: var(--r);
    }

    .slideshow--banner {
        height: 260px;
        border-radius: var(--r);
    }

    /* 表单页幻灯片全宽出血（.container 有 padding 时）
       用负 margin 撑满，避免 100vw 在带滚动条的桌面窗口下产生横向溢出 */
    .slideshow.slideshow--bleed {
        width: auto;
        margin-left: -14px;
        margin-right: -14px;
        border-radius: 0;
    }

    /* 小程序式底部固定操作栏：长表单时提交按钮始终在手边 */
    .form-submit-bar--sticky {
        position: sticky;
        bottom: 0;
        z-index: 60;
        margin: 18px -14px 0;
        padding: 10px 14px calc(10px + var(--safe-bottom));
        background: var(--surface);
        border-top: 1px solid var(--border);
    }
    .form-submit-bar--sticky .btn {
        box-shadow: 0 6px 16px rgba(37, 99, 235, 0.24);
    }

    .page-title {
        font-size: 18px;
        margin: 18px 0 14px;
    }

    .form-group {
        margin-bottom: 18px;
    }

    input[type="text"],
    input[type="tel"],
    input[type="email"],
    input[type="number"],
    input[type="password"],
    select,
    textarea {
        padding: 11px 13px;
    }

    /* 首页查询表单：纵向堆叠 */
    .form-row {
        flex-direction: column;
        align-items: stretch;
    }

    .search-section,
    .search-panel {
        padding: 18px;
    }

    /* 成功页按钮组：允许换行，避免文字挤压 */
    .btn-group {
        flex-wrap: wrap;
    }
    .btn-group .btn {
        flex: 1 1 calc(50% - 6px);
    }

    /* 信息页内边距收窄 */
    .info-page .body {
        padding: 18px 18px 6px;
    }
    .info-hero,
    .info-page .header {
        padding: 22px 20px;
    }
    .info-list .k {
        flex-basis: 84px;
    }
}

/* ---------- 小屏手机（≤480px） ---------- */
@media (max-width: 480px) {
    .slideshow {
        height: 200px;
    }
    .slideshow--banner {
        height: 230px;
    }

    /* 多选项：窄屏改两列紧凑排布（缩短表单纵向长度），文字过长时自动换行不截断 */
    .checkbox-group,
    .radio-group {
        gap: 8px;
    }
    .checkbox-item,
    .radio-item {
        flex: 1 1 calc(50% - 4px);
        min-width: 0;
        padding: 9px 10px;
        font-size: 13px;
        gap: 6px;
    }
    .checkbox-item input[type="checkbox"],
    .checkbox-item input[type="radio"],
    .radio-item input[type="radio"] {
        width: 17px;
        height: 17px;
    }

    .card,
    .panel {
        padding: 18px;
    }

    .success-page .container,
    .info-page .container {
        margin-top: 14px;
        margin-bottom: 14px;
    }

    .reg-no .value {
        font-size: 20px;
    }

    /* 成功页三按钮：单列全宽更易点 */
    .btn-group .btn {
        flex-basis: 100%;
    }
}

/* ---------- 超小屏（≤360px，如 iPhone SE1 / 小安卓） ---------- */
@media (max-width: 360px) {
    .container {
        padding: 12px;
    }
    .slideshow {
        height: 180px;
    }
    /* 出血元素跟随容器内边距收窄，保持左右铺满且不溢出 */
    .slideshow.slideshow--bleed {
        margin-left: -12px;
        margin-right: -12px;
    }
    .form-submit-bar--sticky {
        margin-left: -12px;
        margin-right: -12px;
        padding-left: 12px;
        padding-right: 12px;
    }
    .entry-hero h1 {
        font-size: 19px;
    }
    .option-card,
    .entry-card {
        padding: 16px;
    }
}

/* ---------- 横屏手机：压低幻灯片，避免一屏全是图 ---------- */
@media (max-height: 480px) and (orientation: landscape) {
    .slideshow,
    .slideshow--banner {
        height: 180px;
    }
}

/* ---------- 减少动态偏好：关闭非必要动画 ---------- */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
